I want, as Sparkle/XData server is processing a request, to send a message to a MQTT channel:
A client connects to the Sparkle/XData server and the server must send a message to a MQTT channel in a MQTT server (probably in the same machine).
The current TMS MQTT implementation is non-blocking.
How can I deal with asynchronous processing like that?
Do I need to create a new module for Sparkle?
Thank you in advance
What is the problem with TMS MQTT being non-blocking? If you want the Sparkle server to responde only after the MQTT communication is done, you will have to do some kind of thread synchronization to wait for the MQTT to complete and only then proceed with the Sparkle request processing.