Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is MQTTClient thread-save? #1

Open
goetzvr opened this issue May 30, 2018 · 0 comments
Open

Is MQTTClient thread-save? #1

goetzvr opened this issue May 30, 2018 · 0 comments

Comments

@goetzvr
Copy link
Contributor

goetzvr commented May 30, 2018

From dustsensord logging:

2018-05-30 12:03:46.329 (8248.138s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=9.3
2018-05-30 12:03:47.329 (8249.139s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.5 PM10=9.9
2018-05-30 12:03:48.330 (8250.139s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.6 PM10=9.8
2018-05-30 12:03:49.330 (8251.139s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.5 PM10=9.8
2018-05-30 12:03:50.330 (8252.140s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=9.8
2018-05-30 12:03:51.331 (8253.140s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=9.7
2018-05-30 12:03:52.331 (8254.140s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=10.1
2018-05-30 12:03:53.331 (8255.140s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=10.1
2018-05-30 12:03:54.331 (8256.141s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=10.1
2018-05-30 12:03:55.332 (8257.141s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=10
2018-05-30 12:03:56.332 (8258.141s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=8.8
2018-05-30 12:03:57.332 (8259.142s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.3 PM10=8.7
2018-05-30 12:03:58.333 (8260.142s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.3 PM10=8.5
2018-05-30 12:03:59.333 (8261.142s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.4 PM10=8.6
2018-05-30 12:04:00.333 (8262.142s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.3 PM10=8.6
2018-05-30 12:04:01.333 (8263.143s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.3 PM10=8.7
2018-05-30 12:04:02.334 (8264.143s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.3 PM10=8.4
2018-05-30 12:04:03.334 (8265.143s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.3 PM10=8.4
2018-05-30 12:04:04.334 (8266.144s) [nsor/bbe4/pm2.5 ]               main.cpp:108      0| Sensor 48100: PM2.5=6.2 PM10=8.4

I would have expected logging from mqtt10 and mqtt25

mosquitto_sub gives both queues:

$ mosquitto_sub -h buttercup-cumbersnatch.local -v -t "dustsensor/#"
dustsensor/bbe4/pm2.5 6.6
dustsensor/bbe4/pm10 10.0
dustsensor/bbe4/pm2.5 6.7
dustsensor/bbe4/pm10 9.8
dustsensor/bbe4/pm2.5 6.6

the linux process list gives both queues as well

$ ps  H -o 'pid tid cmd comm' | grep dust
 2403  2403 grep --color=auto dust      grep
25074 25074 ./bin/dustsensord           nsor/bbe4/pm2.5
25074 25076 ./bin/dustsensord           dustsensord
25074 25077 ./bin/dustsensord           ensor/bbe4/pm10
goetzvr added a commit that referenced this issue May 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant