hunterloftis / hunterloftis/jackrabbit

Not handling ETIMEDOUT error exception

Open
#65 1 comment 0 reactions 0 assignees View on GitHub
question
Dominant language
JavaScript
Stars
291
Forks
65
PR merge metrics
No merged PRs in 30d

Description

If this is not the best place to post this, please let me know and my apologies. I am experiencing an issue when I put my computer to sleep for a longish period of time and then reopen it. I am leaving the node process running and when I wake it up I see the error below.

I am wondering where I should be handling this error event. I have pasted the code I use to instantiate jackrabbit below, I would have thought this error would have passed through the error handler I setup but it doesn't seem to. Any ideas where I should be listening for this error?

```
events.js:160
throw er; // Unhandled 'error' event
^

Error: read ETIMEDOUT
at exports._errnoException (util.js:1036:11)
at TCP.onread (net.js:564:26)
```

```
const jackrabbit = require('jackrabbit');
this.queue = jackrabbit(rabbitUrl)
.on('connected', () => {
console.info({ type: 'info', msg: 'connected', service: 'rabbitmq' });
ready();
})
.on('error', (err) => {
console.error({ type: 'error', msg: err, service: 'rabbitmq' });
})
.on('disconnected', () => {
console.warn({ type: 'error', msg: 'disconnected', service: 'rabbitmq' });
lost();
});
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.