When mqtt client gets offline, an error message is trown in the console #1872
-
Hello, I'm developing Next Js 14 app, which usses mqtt as real time data broker.
and after that I'm exposing the mqttClient module to another place, where it's used. (In that particular case in Route Handler GET function). Everything is working fine, till the moment the broker gets disconnected, which happens every couple of minutes. Then I'm getting this error:
It seems like the reconnection works, because I'm getting logs for those events and the app gets automatically reconnected after a few moments after the error has been thrown. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
It seems that I had to additionally install the bufferutil library, which is used by ws, which is used by mqtt. This solved my problem. |
Beta Was this translation helpful? Give feedback.
It seems that I had to additionally install the bufferutil library, which is used by ws, which is used by mqtt. This solved my problem.