dotnet/systemweb-adapters

Ask about HttpResponse.BufferOutput

Clounea opened this issue · 1 comments

Summary

Our repo uses HttpResponse.BufferOutput which is not supported by ASP.NetCore and this adapters.
I want to ask if there is equivalent and if there is plan to add them to adapter.

Motivation and goals

We need migrate code (an API in Sharepoint) to ASP.NetCore and we find that the APIs are not supported by ASP.NetCore.

In scope

HttpResponse.BufferOutput

I saw the comment in Harry's Issue #91
Could you explain more here?

Examples

bool hasWrittenResponse = !httpResponse.BufferOutput || httpResponse.DangerousInvoke<HttpResponse, int>("GetBufferedLength") > 0;

Looks like you just the need the getter. That can be enabled by adding the following:

internal interface IHttpResponseBufferingFeature
{
+   IsEnabled { get; }
}

Setting the value would be more complicated; if this is sufficient, feel free to submit a PR to enable this