Use endHandler in flaky NetTest.testListenDomainSocketAddress#6217
Open
gaganis wants to merge 1 commit into
Open
Use endHandler in flaky NetTest.testListenDomainSocketAddress#6217gaganis wants to merge 1 commit into
gaganis wants to merge 1 commit into
Conversation
This test is flaky and fails in CI builds(3/40 failed builds up to 25/6/2026). endHandler appears as a more appropriate function to ensure that all of the socket data are consumed becuase of two reasons: * It is used by io.vertx.core.streams.ReadStream#collect to read an entire read stream and also * The documentation of endHandler mentions the following "This handler might be called after the close handler when the socket is paused and there are still buffers to deliver." While in the test we do not have a clear pause event happening but it suggests that closeEvent might be called before all buffers have been delivered.
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.
This test is flaky and fails in CI builds(3/40 failed builds up to 25/6/2026). endHandler appears as a more appropriate function to ensure that all of the socket data are consumed because of two reasons:
Motivation:
While developing #6215 I encountered various failures and I have done an investigation of flaky builds. This was one of the top flaky tests and I investigated it further. This change does not guarantee that it will fix the flakyness but it is equivalent locally, the tests pass, so in my opinion this is a good change to try.
I have also changed the order of expected and actual in the assertion. The expected should be the input that was transfered through the socket and the actull what was read from the client. Before this change this was not true.
Conformance:
You should have signed the Eclipse Contributor Agreement as explained in https://github.com/eclipse/vert.x/blob/master/CONTRIBUTING.md
Please also make sure you adhere to the code style guidelines: https://github.com/vert-x3/wiki/wiki/Vert.x-code-style-guidelines