Use of QOS 2 for fast mqtt communication

71 views
Skip to first unread message

kushal bhatta

unread,
Feb 14, 2017, 4:45:25 AM2/14/17
to MQTT
hello everyone,
apologies from me if i weren't clear from the last posts.I was reading some blogs about someone's experiments regarding sending sensor data in bulk and i am also doing nearly the same scenario sending sensor data from different paho clients at very small intervals(in milliseconds or seconds) so in that case if i use qos 2 for publishing data from broker or client will it result in any loss of packets from either end(i dont know when i am running it for 10 minutes or so i see that there is some packet loss ,the server fails to complete the 4 way communication;PUBLISH PUBRECV PUBREL PUBCOMP sometimes it gets stuck receiving PUBRECV and fails to deliver PUBREL most of the times the communication is successful).Waiting for any useful response from your part.

Filipe Nicoli

unread,
Feb 14, 2017, 12:05:58 PM2/14/17
to MQTT
sending sensor data from different paho clients at very small intervals(in milliseconds or seconds)

Do you really need QoS 2 for that?
Can't your application work with QoS 1 or even QoS 0?

kushal bhatta

unread,
Feb 15, 2017, 12:46:07 AM2/15/17
to MQTT
Actually am putting random qos to every sensor data so qos 0 1 2 is utilized in a random fashion and now its working i hope there was some bug in the broker side but the packet s on the client side are coming in different order than that from broker side

Thomas

unread,
Feb 15, 2017, 3:27:25 AM2/15/17
to MQTT
I would first decide what the appropriate level of QoS is for my use case and then stick with that. If you are getting problems with that you should attempt and debug it.

By making things random I suspect you are just making things more complicated for yourself.

Thomas

kushal bhatta

unread,
Feb 15, 2017, 3:48:13 AM2/15/17
to MQTT
actually my company has told me to make a test bench in order to check for robustness of my broker so my boss told me to make configuration file where the number of clients will be random attached to random topics and to random qos for the debugging purpose i was first testing it with only qos 2 but since i dont know the exact use case till now i am sticking up with my boss's proposal

Nick O'Leary

unread,
Feb 15, 2017, 3:54:59 AM2/15/17
to MQTT

So you are choosing to make your task much harder rather than take a structured approach and debug one thing at a time?

Focus on one QoS at a time. Ensure each is working properly and then start mixing them.

Or, just use mosquitto which is open source and is well proven to work. Writing your own broker is not a trivial task.

Nick


On Wed, 15 Feb 2017, 08:48 kushal bhatta, <bhattachar...@gmail.com> wrote:
actually my company has told me to make a test bench in order to check for robustness of my broker so my boss told me to make configuration file where the number of clients will be random attached to random topics and to random qos for the debugging purpose i was first testing it with only qos 2 but since i dont know the exact use case till now i am sticking up with my boss's proposal

--
To learn more about MQTT please visit http://mqtt.org
---
You received this message because you are subscribed to the Google Groups "MQTT" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mqtt+uns...@googlegroups.com.
To post to this group, send email to mq...@googlegroups.com.
Visit this group at https://groups.google.com/group/mqtt.
For more options, visit https://groups.google.com/d/optout.

kushal bhatta

unread,
Feb 15, 2017, 4:25:27 AM2/15/17
to MQTT
ok i will keep that in mind :)
Reply all
Reply to author
Forward
0 new messages