# Duplicate uplinks during ACK retry

**URL:** <https://www.thethingsnetwork.org/forum/t/duplicate-uplinks-during-ack-retry/36287>\
**Category:** v2 Backend\
**Created:** [April 19, 2020, 7:04pm UTC](https://www.thethingsnetwork.org/forum/t/duplicate-uplinks-during-ack-retry/36287 "2020-04-19T19:04:25Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![homelync](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/homelync/32/25844_2.png) [@homelync](https://www.thethingsnetwork.org/forum/u/homelync)\
**Post date:** [April 19, 2020, 7:04pm UTC](https://www.thethingsnetwork.org/forum/t/duplicate-uplinks-during-ack-retry/36287/1 "2020-04-19T19:04:25Z")

</div>

Hi all,

I’m seeing an issue where I’m getting duplicate uplink messages appearing in TTN (and to my MQTT subscription) when I have acknowledgements enabled. It doesn’t happen all the time, roughly 50% of messages are duplicated

![image](https://www.thethingsnetwork.org/forum/uploads/default/original/3X/2/0/205d7565c58cec9264ad1808c043f1f3d9458890.png)

You can see that the payload and fcnt are the same for several messages. What I suspect is happening is that the uplink is getting to the gateway, the gateway is sending the ACK back to the device to acknowledge receipt but the device is not receiving this and so decides to send it again. This is all totally understandable. What I don’t understand is why the network server isn’t seeing these messages as duplicates and doing it’s magic to remove them? Does the de-duplication only apply to messages sent at the same time and received by different gateways? I understand that use case but I’d still have thought that messages with the same payload and fcnt would also be de-duplicated.

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [April 19, 2020, 8:10pm UTC](https://www.thethingsnetwork.org/forum/t/duplicate-uplinks-during-ack-retry/36287/2 "2020-04-19T20:10:28Z")

</div>

If you look at the console you notice these messages are retransmissions, it clearly states ‘retry’. (and the cause is likely that the node does not receive the ack as you suggest.)  
You might not want to see those duplicates, but other application developers might want to know a retry was received. So I am glad the backend lists both messages and enables me to choose how to handle them.

Btw, when sending confirmed uplinks keep in mind you are allowed only 10 ACKs per node per day. Sending a packet every 5 minutes is a clear breach of the fair access policy!

---

<div class="post-metadata">

**Author:** ![homelync](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/homelync/32/25844_2.png) [@homelync](https://www.thethingsnetwork.org/forum/u/homelync)\
**Post date:** [April 19, 2020, 11:00pm UTC](https://www.thethingsnetwork.org/forum/t/duplicate-uplinks-during-ack-retry/36287/3 "2020-04-19T23:00:27Z")

</div>

Thanks @kersing once again for answering my question. I have now realised that in my mqtt subscription received message I have the “is\_retry” flag, so I can use this to dictate my handling logic, so for my current use case, all is good.

Thanks for the heads up on the fair access policy, rest assured, I’m not leaving ACKs turned on, I’m just in the process of testing and experimenting (and learning) so wanted to play around with all of the options available. The 5 min tx is also just whilst I’m testing as it means I’ve got a tighter feedback loop. I’ve also installed an outdoor gateway on the top of a 4 story building - so giving back too. 🙂

![image](https://www.thethingsnetwork.org/forum/uploads/default/original/3X/8/d/8d1dee92018dde1a7dd656014bff0135999c1c78.jpeg)

Thanks again

---

<div class="post-metadata">

**Author:** ![kersing](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/kersing/32/44777_2.png) [@kersing](https://www.thethingsnetwork.org/forum/u/kersing)\
**Post date:** [April 20, 2020, 3:35pm UTC](https://www.thethingsnetwork.org/forum/t/duplicate-uplinks-during-ack-retry/36287/4 "2020-04-20T15:35:09Z")

</div>

> [@homelync](#):
>
> so giving back too

Excellent, however that doesn’t mean you should be sending too often as you are still using a shared medium (radio waves). 🙂

---

<div class="post-metadata">

**Author:** ![homelync](https://www.thethingsnetwork.org/forum/user_avatar/www.thethingsnetwork.org/homelync/32/25844_2.png) [@homelync](https://www.thethingsnetwork.org/forum/u/homelync)\
**Post date:** [April 21, 2020, 5:27am UTC](https://www.thethingsnetwork.org/forum/t/duplicate-uplinks-during-ack-retry/36287/5 "2020-04-21T05:27:15Z")

</div>

Yep, understood. Thanks
