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

No Ack received when msg published to local broker #287

Open
rndalteem opened this issue Jun 6, 2022 · 1 comment
Open

No Ack received when msg published to local broker #287

rndalteem opened this issue Jun 6, 2022 · 1 comment

Comments

@rndalteem
Copy link

rndalteem commented Jun 6, 2022

Everything is working perfact when Online Broker is used but when we switched to local broker problem arises.
No Pulish Complete callback is received whe msg with qos2 is published which in turn block whole msg sending logic.

I am attaching debug msges with verbose mode.

16:58:34.625 -> INFO : Data Rx on Uart1,Length : 0,Data : {"DISX":"L007","ID":10,"X0":0,"X1":0,"X2":0,"X3":0,"X4":0,"X5":0,"X6":0,"X7":0,"X8":0,"X9":0}
16:58:34.661 -> INFO : Temp_SaveBuffer : {"TS":"2022-06-06T16:58:01","DISX":"L007","ID":10,"X0":0,"X1":0,"X2":0,"X3":0,"X4":0,"X5":0,"X6":0,"X7":0,"X8":0,"X9":0}
16:58:34.661 -> INFO : Published Zigbee SerialData Message
16:58:37.948 -> [1149709][I][AsyncMqttClient.cpp:675] _sendPing(): PING
16:58:37.948 -> [1149710][I][AsyncMqttClient.cpp:382] _addBack(): new back #12
16:58:37.948 -> [1149711][I][AsyncMqttClient.cpp:415] _handleQueue(): snd #12: 2/2
16:58:37.948 -> [1149715][I][AsyncMqttClient.cpp:425] _handleQueue(): p #12 rel
16:58:37.948 -> [1149723][I][AsyncMqttClient.cpp:244] _onAck(): ack 2
16:58:37.983 -> [1149725][I][AsyncMqttClient.cpp:249] _onData(): data rcv (2)
16:58:37.983 -> [1149731][I][AsyncMqttClient.cpp:267] _onData(): rcv PINGRESP
16:58:37.983 -> [1149736][I][AsyncMqttClient.cpp:498] _onPingResp(): PINGRESP
16:58:41.933 -> [1153710][I][AsyncMqttClient.cpp:675] _sendPing(): PING
16:58:41.933 -> [1153711][I][AsyncMqttClient.cpp:382] _addBack(): new back #12
16:58:41.967 -> [1153712][I][AsyncMqttClient.cpp:415] _handleQueue(): snd #12: 2/2
16:58:41.967 -> [1153716][I][AsyncMqttClient.cpp:425] _handleQueue(): p #12 rel
16:58:41.967 -> [1153732][I][AsyncMqttClient.cpp:244] _onAck(): ack 2
16:58:41.967 -> [1153732][I][AsyncMqttClient.cpp:249] _onData(): data rcv (2)
16:58:41.967 -> [1153732][I][AsyncMqttClient.cpp:267] _onData(): rcv PINGRESP
16:58:41.967 -> [1153737][I][AsyncMqttClient.cpp:498] _onPingResp(): PINGRESP
16:58:45.950 -> [1157711][I][AsyncMqttClient.cpp:675] _sendPing(): PING
16:58:45.950 -> [1157712][I][AsyncMqttClient.cpp:382] _addBack(): new back #12
16:58:45.950 -> [1157713][I][AsyncMqttClient.cpp:415] _handleQueue(): snd #12: 2/2
16:58:45.950 -> [1157717][I][AsyncMqttClient.cpp:425] _handleQueue(): p #12 rel
16:58:45.950 -> [1157722][I][AsyncMqttClient.cpp:244] _onAck(): ack 2
16:58:45.984 -> [1157727][I][AsyncMqttClient.cpp:249] _onData(): data rcv (2)
16:58:45.984 -> [1157733][I][AsyncMqttClient.cpp:267] _onData(): rcv PINGRESP
16:58:45.984 -> [1157738][I][AsyncMqttClient.cpp:498] _onPingResp(): PINGRESP
16:58:49.936 -> [1161712][I][AsyncMqttClient.cpp:675] _sendPing(): PING

Debug msges when publish ok.

17:08:34.618 -> INFO : Data Rx on Uart1,Length : 0,Data : {"DISX":"L007","ID":20,"X0":0,"X1":0,"X2":0,"X3":0,"X4":0,"X5":0,"X6":0,"X7":0,"X8":0,"X9":0}
17:08:34.651 -> INFO : Temp_SaveBuffer : {"TS":"2022-06-06T17:07:11","DISX":"L007","ID":20,"X0":0,"X1":0,"X2":0,"X3":0,"X4":0,"X5":0,"X6":0,"X7":0,"X8":0,"X9":0}
17:08:34.651 -> INFO : Published Zigbee SerialData Message
17:08:34.651 -> INFO : Publishing Zigbee Message Topic-/AR/DS/ZB/E001/D DataLen-123 Qos-2
17:08:34.685 -> [ 54411][I][AsyncMqttClient.cpp:741] publish(): PUBLISH
17:08:34.685 -> [ 54412][I][AsyncMqttClient.cpp:382] _addBack(): new back #3
17:08:34.685 -> [ 54414][I][AsyncMqttClient.cpp:415] _handleQueue(): snd #3: 146/146
17:08:34.685 -> INFO : Published Zigbee Message,Topic:/AR/DS/ZB/E001/D packet id 7
17:08:34.685 -> [ 54436][I][AsyncMqttClient.cpp:244] _onAck(): ack 146
17:08:34.685 -> [ 54436][I][AsyncMqttClient.cpp:249] _onData(): data rcv (4)
17:08:34.718 -> [ 54436][I][AsyncMqttClient.cpp:291] _onData(): rcv PUBREC
17:08:34.718 -> [ 54441][I][AsyncMqttClient.cpp:652] _onPubRec(): snd PUBREL
17:08:34.718 -> [ 54446][I][AsyncMqttClient.cpp:657] _onPubRec(): PUB released
17:08:34.718 -> [ 54451][I][AsyncMqttClient.cpp:354] _insert(): new insert #6
17:08:34.718 -> [ 54457][I][AsyncMqttClient.cpp:425] _handleQueue(): p #3 rel
17:08:34.718 -> [ 54463][I][AsyncMqttClient.cpp:415] _handleQueue(): snd #6: 4/4
17:08:34.751 -> [ 54487][I][AsyncMqttClient.cpp:244] _onAck(): ack 4
17:08:34.751 -> [ 54487][I][AsyncMqttClient.cpp:249] _onData(): data rcv (4)
17:08:34.751 -> [ 54487][I][AsyncMqttClient.cpp:295] _onData(): rcv PUBCOMP
17:08:34.751 -> [ 54491][I][AsyncMqttClient.cpp:668] _onPubComp(): PUBREL released
17:08:34.751 -> Publish acknowledged.
17:08:34.751 ->   packetId: 7
17:08:35.051 -> [ 54791][I][AsyncMqttClient.cpp:425] _handleQueue(): p #6 rel
@bertmelis
Copy link
Contributor

The log doesn't show a publish message. Please include your publishing code. Does the publish function return a packet ID? (or 1 if qos == 0)

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

2 participants