A custom HttpContent that wraps a rented byte array from an ArrayPool, writes only the valid byte range to outgoing streams, and returns the buffer to the pool when disposed to reduce GC allocations.
-
Updated
Jan 15, 2026 - C#
A custom HttpContent that wraps a rented byte array from an ArrayPool, writes only the valid byte range to outgoing streams, and returns the buffer to the pool when disposed to reduce GC allocations.
A collection of helpful HttpContent extension methods
Add a description, image, and links to the httpcontent topic page so that developers can more easily learn about it.
To associate your repository with the httpcontent topic, visit your repo's landing page and select "manage topics."