Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mosquitto-dev] Single threaded bridge

 No, Mosquitto implemented with the asynchronous and non-blocking event drive behavior which means try to connect to the remote broker would never block local dispatches. I guess there's some errors else in your case. Do you have the log for further analyze?


From: mosquitto-dev-bounces@xxxxxxxxxxx <mosquitto-dev-bounces@xxxxxxxxxxx> on behalf of Niccolo Battezzati <niccolo.battezzati@xxxxxxxxxxxxxxx>
Sent: Wednesday, February 7, 2018 17:18
To: mosquitto-dev@xxxxxxxxxxx
Subject: [mosquitto-dev] Single threaded bridge
 

Hi all,

 

I’m facing the following issue with the moquitto bridge functionality.

I have a mosquitto bridge that is working as a local broker (with clients on the same machine) and that bridges some topics to/from a remote broker.

However, if the bridge  cannot connect to the remote broker (indeed my operation environment cannot guarantee full internet connectivity always) it periodically hangs for about 30 seconds trying to connect and during this time it does not dispatch messages to the local clients any more. So, basically if the bridge cannot connect to the remote broker, even the local broker functionality is broken.

 

I guess the cause of this behavior is that there is only one thread that dispatches messages (local broker) and tries to connect to the remote broker (bridge), and, in my particular case, it remains stucked in the attempt of resolving the remote broker address.

 

Do you have any idea on ow to solve this problem? I would need that the local broker could continue to dispatch messages among local clients even if the bridge cannot communicate to the remote broker

 

Is there any branch or new version that could address this topic?

 

Thank you very much,

Niccolò


Back to the top