Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[paho-dev] Automatic Reconnect and Publishing While Disconnected

Hello all,

we're starting to implement automatic reconnect and publish while disconnected (offline buffering) for the
Java, _javascript_ and C clients.  I've drawn up a state diagram of how this might work, which I've attached below.

This means that the application has to call connect before being able to publish - it doesn't matter whether the
connect call succeeds or not. 

Operations are: connect, reconnect, disconnect.
Events are: connectionLost, onConnect

The reconnect operation can occur automatically, or "manually" when called by the application.   Persistent
messages can be managed by API calls before connect is called.

Let me know if you have any thoughts or suggestions.

-- 
Ian Craggs                          
icraggs@xxxxxxxxxx                 IBM United Kingdom
Paho Project Lead; Committer on Mosquitto


Back to the top