Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Attempt to fix the flaky TestTriggererJob test (#34075)
As documented in #33323, we have frequent failures of the flaky triggerer job tests. The flaky failures are about some errors when we close all the sessions in teardown of the test. It turns out that the tests had side-effect - they have not waited for the TriggererJob thread to complete, they merely marked them to be stopped, but they have not waited for those to complete - this is quite plausible explanation of the flaky test failures - since those threads have 1 second sleep, it's more than likely that the session has been created and used by the thread while the teardown has been attempting to close all the sessions. This side effect could also have an effect for other tests that were run after - because in a busy test run machine, the side effects could propagate further than just to the teardown, so it could also explain why sometimes (very rarely) other job tests failed with similar errors. The fix is to join the runner after marking it to be stopped. Fixes: #33323 (Hopefully)
- Loading branch information