packetdrill: implement relative time tolerance#42
Open
sheepx86 wants to merge 3 commits intogoogle:masterfrom
Open
packetdrill: implement relative time tolerance#42sheepx86 wants to merge 3 commits intogoogle:masterfrom
sheepx86 wants to merge 3 commits intogoogle:masterfrom
Conversation
wdebruij
reviewed
Aug 13, 2020
Contributor
wdebruij
left a comment
There was a problem hiding this comment.
Can you please clean up the commit message for this commit?
packetdrill tries to accommodate difference between expected time and observed time using a (configurable) maximum value of the difference. Add a percentage based tolerance, which is helpful for long running tests. Default of 0.5 % means that 5ms of drift per second is allowed. If one event happens 10 seconds after the last one, the tolerance would be 50 ms. Can be changed with --tolerance_percent=<percentage>
Packetdrill calculates the dynamic tolerance based on delta between time of the last and current event. This delta value is irrelevant for a blocking system call and the last event is unpredictable and depends on the timing. Instead we can use the delta between the start and end time specified in the packetdrill with an ellipse.
Packetdrill checks difference between expected time and observed time using a tolerance, which is set as the higher of a fixed value (tolerance_usecs) or a percentage(tolerance_percent) times duration. Extend this check for SCM_TIMESTAMPING records.
dcaratti
pushed a commit
to dcaratti/packetdrill
that referenced
this pull request
Feb 25, 2021
mptcp: new syscall test for full DATA_FIN handshake after close
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.
Packetdrill tries to accommodate difference between expected time and observed time using a (configurable) maximum value of the difference.
For tests runing on slow hosts or with long running tests, the fixed tolerance may cause the test fail.
Add a new flag
--tolerance_percentto allow the tolerance relative to the time difference of events. Default of 0.5 % means that 5ms of drift per second is allowed. The flag also applies to SCM_TIMESTAMPING records.