2

I've been developing a node server (v.12) with Express (4.0) for some time. Starting last week, I randomly started getting these events. I've reviewed other stack exchange questions, and they indicated to make sure I'm calling the callbacks. I've gone through my app and everything looks correct. There is no pattern to when I get these, I cannot predict them, so I tend to think that the browser is actually hanging up. How can I add proper error handling or debug this further? I would have expected that Express would handle a common browser disconnect? Or is this something else?

events.js:85
      throw er; // Unhandled 'error' event
        ^
Error: socket hang up
    at createHangUpError (_http_client.js:215:15)
    at Socket.socketOnEnd (_http_client.js:293:23)
    at Socket.emit (events.js:129:20)
    at _stream_readable.js:908:16
    at process._tickCallback (node.js:355:11)

Not a lot of code has been added recently, only tweaks, but load has picked up. To be clear this is my node.js server handling a request from a browser. (Other questions on SO are for handling this on requests to other servers)

user9170
  • 950
  • 9
  • 18
  • Can you duplicate this in a development environment? If you can, can you duplicate this with a simplified version of your system? – Randy Apr 27 '15 at 19:00

0 Answers0