Need more help on mosquitto_loop_misc

Asked by Tushar

I am using mosquitto_loop function to monitor the connection.
To have finer information i guess, mosquitto_loop_misc is the solution.
But i am not able to recognize how to use mosquitto_loop_misc, mosquitto_loop_read and mosquitto_loop_write to achieve this.
Can any one help and provide more information on this.

Thank You

Question information

Language:
English Edit question
Status:
Solved
For:
mosquitto Edit question
Assignee:
No assignee Edit question
Solved by:
Roger Light
Solved:
Last query:
Last reply:
Revision history for this message
Best Roger Light (roger.light) said :
#1

mosquitto_loop() runs the network code, it isn't directly for
monitoring, although it does allow you to get some information from
its return code. You don't get any other information from calling
mosquitto_loop_read/write/misc except that the network connection
failed on a read or a write, but that doesn't get you anything in my
opinion.

mosquitto_loop_read/write/misc are for integrating the library into an
external select/poll/epoll/event library loop, nothing more.

On Wed, Jun 4, 2014 at 8:41 AM, Tushar
<email address hidden> wrote:
> New question #249732 on mosquitto:
> https://answers.launchpad.net/mosquitto/+question/249732
>
> I am using mosquitto_loop function to monitor the connection.
> To have finer information i guess, mosquitto_loop_misc is the solution.
> But i am not able to recognize how to use mosquitto_loop_misc, mosquitto_loop_read and mosquitto_loop_write to achieve this.
> Can any one help and provide more information on this.
>
> Thank You
>
> --
> You received this question notification because you are a member of
> Mosquitto PPA, which is an answer contact for mosquitto.

Revision history for this message
Tushar (tusharforever) said :
#2

Thank You Roger Light for the information.

Revision history for this message
Tushar (tusharforever) said :
#3

Does mosquitto provide any support to monitor the ping requests

Revision history for this message
Tushar (tusharforever) said :
#4

Thanks Roger Light, that solved my question.