[MXS-4195] test_atomic times out intermittently during packaging Created: 2022-07-07 Updated: 2022-07-15 Resolved: 2022-07-15 |
|
| Status: | Closed |
| Project: | MariaDB MaxScale |
| Component/s: | Core |
| Affects Version/s: | 2.5.20 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | markus makela | Assignee: | markus makela |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
The test_atomic test seems to time out from time to time which causes builds to fail. Repeated local tests have revealed no problems which could suggest the problem is related to the build environment. |
| Comments |
| Comment by markus makela [ 2022-07-08 ] | ||||||||
|
Stacktrace from a test run:
| ||||||||
| Comment by markus makela [ 2022-07-08 ] | ||||||||
|
The test is faulty as it expects all threads to complete their tasks in some given order. If the previous thread ends up not executing the code that is expected and returns earlier than the current thread (a perfectly valid outcome) the test ends up waiting for the previous thread to assign the ID value to the current thread. Since the loop doesn't check for the flag that tells the test to stop, it ends up timing out. Since the atomic_cas_ptr function isn't used anywhere, it might as well be removed along with the test case for it. | ||||||||
| Comment by markus makela [ 2022-07-15 ] | ||||||||
|
Fixed the test for 2.5.21. |