Skip to content

Investigate different thread allocation semantics under the hood #190

@farmdawgnation

Description

@farmdawgnation

It's been reported that every time an Http is constructed, we get 2*$numCpus threads created by AHC because we create an AHC client on each invocation. Some things to look at:

  • One option that's been suggested is to share an AHC client instance under the hood, which is thread-safe "with qualification" - specifically so long as you don't do anything not-thread-safe in your callbacks. The with qualification bit is what scares me about that.
  • Perhaps a more targeted approach is to expose or better document a knob for the number of threads that we should allocate when we build the client.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions