Skip to content

Cache agent#1122

Merged
chrmarti merged 2 commits intomainfrom
chrmarti/nervous-fish
Sep 24, 2025
Merged

Cache agent#1122
chrmarti merged 2 commits intomainfrom
chrmarti/nervous-fish

Conversation

@chrmarti
Copy link
Collaborator

@chrmarti chrmarti commented Sep 24, 2025

Copilot AI review requested due to automatic review settings September 24, 2025 07:45
@chrmarti chrmarti enabled auto-merge September 24, 2025 07:45
@chrmarti chrmarti self-assigned this Sep 24, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements connection pooling by caching a single undici.Agent instance for HTTP requests, improving performance by reusing connections instead of creating a new agent for each request.

  • Introduces a cached agent pattern to avoid creating new undici.Agent instances on every request
  • Implements lazy initialization of the agent with HTTP/2 support enabled

@vs-code-engineering vs-code-engineering bot added this to the September 2025 milestone Sep 24, 2025
Copy link
Contributor

@dmitrivMS dmitrivMS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please see my comment inline

@chrmarti chrmarti added this pull request to the merge queue Sep 24, 2025
Merged via the queue into main with commit 027a33a Sep 24, 2025
16 checks passed
@chrmarti chrmarti deleted the chrmarti/nervous-fish branch September 24, 2025 13:29
chrmarti added a commit that referenced this pull request Oct 2, 2025
* Cache agent

* Use Lazy
TylerLeonhardt pushed a commit that referenced this pull request Oct 2, 2025
* Cache agent (#1122)

* Cache agent

* Use Lazy

* Update version to 0.31.4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants