You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using MQTT via the fluid.paho_mqtt nuget in a C++ application.
The application is multi threaded and I have read the https://eclipse-paho.github.io/paho.mqtt.c/MQTTClient/html/async.html.
I use the MQTTClient_subscribe and MQTTClient_publishMessage functions.
In my MessageArrived callback I put the MQTTClient_message in a que and process that in a separate thread, So the processing is very short.
If I understand the page correctly I can call MQTTClient_publishMessage from different threads as long as I synchronise the access. So the method is called from different threads but never from two thread simultaneously.
Is this correct ?
I am a bit unsure on exactly what this means "This API is not thread safe however - it is not possible to call it from multiple threads without synchronization. You can use the MQTTAsync API for that."
I did not find much documentation on the MQTTAsync API.
Currently I have an issue that when I send 10.000 updates on a topic that I both publish and subscribe some of the updates are not arriving.
I have set the QOS to 2 for both publish and subscribe.
If I use another client to subscribe the topic it looks like all the updates are arriving.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Hi
I am using MQTT via the fluid.paho_mqtt nuget in a C++ application.
The application is multi threaded and I have read the https://eclipse-paho.github.io/paho.mqtt.c/MQTTClient/html/async.html.
I use the MQTTClient_subscribe and MQTTClient_publishMessage functions.
In my MessageArrived callback I put the MQTTClient_message in a que and process that in a separate thread, So the processing is very short.
If I understand the page correctly I can call MQTTClient_publishMessage from different threads as long as I synchronise the access. So the method is called from different threads but never from two thread simultaneously.
Is this correct ?
I am a bit unsure on exactly what this means "This API is not thread safe however - it is not possible to call it from multiple threads without synchronization. You can use the MQTTAsync API for that."
I did not find much documentation on the MQTTAsync API.
Currently I have an issue that when I send 10.000 updates on a topic that I both publish and subscribe some of the updates are not arriving.
I have set the QOS to 2 for both publish and subscribe.
If I use another client to subscribe the topic it looks like all the updates are arriving.
Thanks for any input.
/Kennet
All reactions