Skip to content

Reduce allocation cost of HttpRequestOptions #87234

@antonfirsov

Description

@antonfirsov

R9 is using HttpRequestMessage.Properties/Options in several cases and we have plans in #86281 to utilize it further. The property bag contains very few elements typically, so the internal dictionary can be substituted by linear lookup over a list of elements.

My recommendation would be to embed a few key-value pairs and allocate an Array over a threshold, like we do in TagList.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions