easternbloc / node-stomp-client

A STOMP client for Node.js
Other
93 stars 47 forks source link

Error Callback #18

Open tamsler opened 11 years ago

tamsler commented 11 years ago

How does the client get notified, when the server connection goes down? I have defined the "errorCallback" in:

stomp.connect([callback, [errorCallback]])

but it never gets called if the server goes down.

sam-github commented 10 years ago

Have you tried to listen for 'disconnect' event?

ahudak commented 9 years ago

I've run into this same problem. My current workaround is to directly access the stream within the stomp client and bind to the 'end' event.

client.stream.on('end', errorCallback);