NodeJS errno 37 on socket.connect
I am trying to connect to multiple nodes in a row, this is the code to resolve the ip address and socket.connect () for each domain name (line [1]). This works on it, but returns errno 37 on fast startup with different hosts. The best information I have about the error is:
":" EPROTO ", description:" protocol error "
code:
$.connect(port, line[1], function() {
this.write(request);
});
Mistake:
{ [Error: connect Unknown system errno 37]
code: 'Unknown system errno 37',
errno: 'Unknown system errno 37',
syscall: 'connect' }
How can I solve this / why is this happening?
Thanks in advance.
EDIT: Removed manual dns lookup code and added bug report
+3
source to share
1 answer
duplicate from https://stackoverflow.com/questions/14672743/nodejs-crash-when-calling-socket-connect-in-quick-succession
I seem to be opening sockets in quick succession asking for trouble.
Try to wait between opening sockets and playing with the amount of time to wait.
0
source to share