Open
Conversation
|
If the response has payload, also that payload is intended to be sent back in cases of deduplication, not only the response code. |
Contributor
Author
ok, this means we have to store the whole response message with content type etc. to properly answer duplicate messages. This will consume quite some amount of memory. But I agree, it makes sense. |
Contributor
|
Todo: squash fix |
According to rfc 7252, section "4.5. Message Deduplication", duplicate received packets must be dropped. Also "The recipient SHOULD acknowledge each duplicate copy of a Confirmable message using the same Acknowledgement or Reset message [...]". Wakaama identifies a duplicate message based on the message id and the session it was received from. Duplicate messages are then processed only once for the first message, subsequent messages are acked with the corresponding CoAP response code, but not processed further. Duplicate messages are ignored for a predefined time period EXCHANGE_LIFETIME.
Test CoAP message deduplication functions.
9f47dcb to
af09510
Compare
Contributor
|
Squash this PR before merging |
af09510 to
08a48b0
Compare
Previously when a response of a de-duplicated message was resent, only the status code was provided. Now the complete message is stored for retransmission.
a16c790 to
76e7ff2
Compare
Previously when a response of a de-duplicated message was resent, only the status code was provided. Now the complete message is stored for retransmission.
76e7ff2 to
72556b9
Compare
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


According to rfc 7252, section "4.5. Message Deduplication", duplicate received packets must be dropped. Also "The recipient SHOULD acknowledge each duplicate copy of a Confirmable message using the same Acknowledgement or Reset message [...]".
Wakaama identifies a duplicate message based on the message id and the session it was received from. Duplicate messages are then processed only once for the first message, subsequent messages are acked with the
corresponding CoAP response code, but not processed further. Duplicate messages are ignored for a predefined time period EXCHANGE_LIFETIME.