Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TLS error not caught by error event #47

Open
palatinb opened this issue Mar 18, 2022 · 3 comments
Open

TLS error not caught by error event #47

palatinb opened this issue Mar 18, 2022 · 3 comments

Comments

@palatinb
Copy link
Contributor

Hello,

I used your package in one of my app and I noticed that after a time I got ECONNRESET error, but it is not caught in the client.on('error',..) method. As I found out in the in the mqttjs package it is already implemented that, the following TLS errors are emit the error event:

  • ECONNREFUSED
  • ECONNRESET
  • EADDRINUSE
  • ENOTFOUND

Could you please also implement this in this package too?

Thanks,

@mathis92
Copy link

Same issue for me, i am getting some random disconnections from the lib, it is trying to reconnect but it is pretty hard to find the reason of disconnection when there is no error emitted from the lib itself only close and reconnect events.

It would be grate to have this implemented directly to be able to consume also the error events.

thanks

@palatinb
Copy link
Contributor Author

palatinb commented May 4, 2022

Can anybody help?

@RangerMauve
Copy link
Contributor

asyncClient.on('error') should be invoking .on('error') on the underlying MQTT client, so I'm not sure why you aren't catching errors.

Could you post a minimal reproducible test case for this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants