Skip to content

Commit 7288bdf

Browse files
Note for null streams with HttpRequestData
1 parent 49ca41f commit 7288bdf

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

articles/azure-functions/dotnet-isolated-process-guide.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -822,6 +822,9 @@ host.Run();
822822

823823
In the built-in model, the system translates the incoming HTTP request message into an [HttpRequestData] object that is passed to the function. This object provides data from the request, including `Headers`, `Cookies`, `Identities`, `URL`, and optionally a message `Body`. This object is a representation of the HTTP request but isn't directly connected to the underlying HTTP listener or the received message.
824824

825+
> [!IMPORTANT]
826+
> If you use `HttpRequestData`, the body of the HTTP request can't be a stream. For example, if the request has the `Transfer-Encoding: chunked` header and no `Content-Length` header, the `HttpRequestData` object's `Body` property will be a null stream. If you need to work with streaming HTTP requests, consider using the [ASP.NET Core integration model](#aspnet-core-integration) instead.
827+
825828
Likewise, the function returns an [HttpResponseData] object, which provides data used to create the HTTP response, including message `StatusCode`, `Headers`, and optionally a message `Body`.
826829

827830
The following example demonstrates the use of `HttpRequestData` and `HttpResponseData`:

0 commit comments

Comments
 (0)