Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • N node-http-proxy
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 482
    • Issues 482
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 102
    • Merge requests 102
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • http ... PARTY!
  • node-http-proxy
  • Issues
  • #859
Closed
Open
Issue created Aug 02, 2015 by Administrator@rootContributor

Keep-alive broken if target server sends `Connection: close`

Created by: Rush

https://github.com/nodejitsu/node-http-proxy/blob/master/lib/http-proxy/passes/web-outgoing.js#L45

Without agent specified: Browser <-> Proxy - connects with keep-alive Proxy <-> Target server - connects without keep-alive If target server sends Connection: close the first keep-alive connection is broken.

Maybe better logic would be to do by default:

proxyRes.headers.connection = 'keep-alive';

Other option is to simply always use the agent with keepAlive: true which was implemented in Node 0.12 - but as I understand, this would be much more resource hungry.

Assignee
Assign to
Time tracking