Can publisher client queue all the messages it has to publish when the connectivity to mqtt server is lost

Hi @Abhishek ,

Great you are interested in MQTT and HiveMQ client, welcome to the community !

Sounds like you need to implement offline message buffering. Please check out the example of offline message buffering implemented with HiveMQ MQTT Client here: Offline Message Buffering - #3 by Daria_H

I hope this helps,
Dasha from HiveMQ team