8000 Merge pull request #323 from indutny/fix-maciej-issue · unbug/node-http-proxy@3d61877 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3d61877

Browse files
committed
Merge pull request http-party#323 from indutny/fix-maciej-issue
lib: allow overriding maxSockets
2 parents 4d7e8a8 + a487dc9 commit 3d61877

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/node-http-proxy.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -352,6 +352,9 @@ exports._getAgent = function _getAgent (options) {
352352
var Agent = options.https ? https.Agent : http.Agent,
353353
agent;
354354

355+
// require('http-proxy').setMaxSockets() should override http's default
356+
// configuration value (which is pretty low).
357+
options.maxSockets = options.maxSockets || maxSockets;
355358
agent = new Agent(options);
356359

357360
return agent;

0 commit comments

Comments
 (0)
0