Skip to content

Conversation

@bneradt
Copy link
Contributor

@bneradt bneradt commented Feb 8, 2023

This is a second iteration to further improve some of the autests that exercise ATS shutting down during test execution. See #9372 for the previous patch. The previous update improved reliability, but still had a race condition between autest recognizing ATS process shutdown and ATS writing the expected error log. If it detected the ts process ending before the log was written, the autest would fail because the framework thought the process ended before the Ready condition was satisfied. This patch addresses this by using a separate process to wait upon the log entry instead of making the ts Ready condition the content of the log file.

This is a second iteration to further improve some of the autests that
exercise ATS shutting down during test execution. See apache#9372 for the
previous patch. The previous update improved reliability, but still had
a race condition between autest recognizing ATS process shutdown and ATS
writing the expected error log. If it detected the ts process ending
before the log was written, the autest would fail because the framework
thought the process ended before the Ready condition was satisfied. This
patch addresses this by using a separate process to wait upon the log
entry instead of making the ts Ready condition the content of the log
file.
@bneradt bneradt added the AuTest label Feb 8, 2023
@bneradt bneradt added this to the 10.0.0 milestone Feb 8, 2023
@bneradt bneradt self-assigned this Feb 8, 2023
@bneradt
Copy link
Contributor Author

bneradt commented Feb 8, 2023

I'm marking this for 9.2.x because this test-only change should make the tests more reliable there and is therefore probably worth the backport to avoid the inconvenience of false negatives in CI for the 9.2.x branch.

@bneradt bneradt merged commit 086501c into apache:master Feb 8, 2023
@bneradt bneradt deleted the better_ts_shutdown_ci_stability_fixes branch February 8, 2023 22:01
@zwoop
Copy link
Contributor

zwoop commented Feb 22, 2023

This has a series of dependencies on previous changes. If you want this, please mark all the PRs needed for this to properly cherry-pick. Or, make a new 9.2.x PR.

bneradt added a commit to bneradt/trafficserver that referenced this pull request Apr 25, 2023
This is a second iteration to further improve some of the autests that
exercise ATS shutting down during test execution. See apache#9372 for the
previous patch. The previous update improved reliability, but still had
a race condition between autest recognizing ATS process shutdown and ATS
writing the expected error log. If it detected the ts process ending
before the log was written, the autest would fail because the framework
thought the process ended before the Ready condition was satisfied. This
patch addresses this by using a separate process to wait upon the log
entry instead of making the ts Ready condition the content of the log
file.

(cherry picked from commit 086501c)
@bneradt
Copy link
Contributor Author

bneradt commented Apr 25, 2023

This has a series of dependencies on previous changes. If you want this, please mark all the PRs needed for this to properly cherry-pick. Or, make a new 9.2.x PR.

Sounds good:
#9641

zwoop pushed a commit that referenced this pull request Apr 26, 2023
* Fix autest flakiness due better Ready Conditions (#9372)

A number of tests were flakey because of race conditions between the AuTest framework finishing the Default TestRun process and ending the test, and therefore the traffic server process, before traffic server had time to exercise the expected functionality of the test. This improves the Ready conditions for these tests which should improve their reliability.

(cherry picked from commit c175aa4)

* Make autest ts shutdown tests more reliable (#9391)

This is a second iteration to further improve some of the autests that
exercise ATS shutting down during test execution. See #9372 for the
previous patch. The previous update improved reliability, but still had
a race condition between autest recognizing ATS process shutdown and ATS
writing the expected error log. If it detected the ts process ending
before the log was written, the autest would fail because the framework
thought the process ended before the Ready condition was satisfied. This
patch addresses this by using a separate process to wait upon the log
entry instead of making the ts Ready condition the content of the log
file.

(cherry picked from commit 086501c)
masaori335 pushed a commit to masaori335/trafficserver that referenced this pull request Jul 24, 2023
* Fix autest flakiness due better Ready Conditions (apache#9372)

A number of tests were flakey because of race conditions between the AuTest framework finishing the Default TestRun process and ending the test, and therefore the traffic server process, before traffic server had time to exercise the expected functionality of the test. This improves the Ready conditions for these tests which should improve their reliability.

(cherry picked from commit c175aa4)

* Make autest ts shutdown tests more reliable (apache#9391)

This is a second iteration to further improve some of the autests that
exercise ATS shutting down during test execution. See apache#9372 for the
previous patch. The previous update improved reliability, but still had
a race condition between autest recognizing ATS process shutdown and ATS
writing the expected error log. If it detected the ts process ending
before the log was written, the autest would fail because the framework
thought the process ended before the Ready condition was satisfied. This
patch addresses this by using a separate process to wait upon the log
entry instead of making the ts Ready condition the content of the log
file.

(cherry picked from commit 086501c)
(cherry picked from commit a1eb655)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants