Closed sendyhalim closed 1 year ago
Wooops, I'll update the PR to add and fix test cases
This code in this repository has been moved to the proxy-agents
monorepo, so I am closing this pull request. If you feel that this change is still necessary as of the latest release, feel free to open a new pull request over there.
This pull request will make http agent cache key to be customizable, sometimes you don't want to reuse proxy agent. A good example of this would be if I'm sending dynamic http header for proxy (example using superagent-proxy)
The above example wouldn't work,
session-id
will stay the same because proxy agent uses proxy uri as the cache key. By addingproxyAgentCacheKey
options, we can override the cache key.