You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by "Caideyipi (via GitHub)" <gi...@apache.org> on 2026/07/30 10:21:59 UTC
[PR] Fix flaky L1 priority queue blocking test [iotdb]
Caideyipi opened a new pull request, #18364:
URL: https://github.com/apache/iotdb/pull/18364
## Description
Fix a timing race in `L1PriorityQueueTest.testPollBlocked` observed in an unrelated Windows unit-test job.
The test slept for a fixed 100 ms before checking the worker thread state. On a loaded runner, the worker could still be `RUNNABLE`, even though `L1PriorityQueue.poll()` blocks correctly once it reaches the empty queue.
Use Awaitility with a bounded timeout for both the `WAITING` and `TERMINATED` states. This matches the existing synchronization pattern in `L2PriorityQueueTest` and `MultilevelPriorityQueueTest`.
## Tests
- `mvn '-Ddevelocity.off=true' -pl iotdb-core/datanode -am '-Dtest=L1PriorityQueueTest' '-Dsurefire.failIfNoSpecifiedTests=false' test`
- Tests run: 5, failures: 0, errors: 0
<hr>
This PR has:
- [x] been self-reviewed.
- [x] replaced fixed sleeps with bounded condition waits.
- [x] reused the established pattern from sibling queue tests.
- [x] passed the targeted DataNode unit test locally.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix flaky L1 priority queue blocking test [iotdb]
Posted by "Caideyipi (via GitHub) via reviews" <re...@iotdb.apache.org>.
Caideyipi closed pull request #18364: Fix flaky L1 priority queue blocking test
URL: https://github.com/apache/iotdb/pull/18364
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fix flaky L1 priority queue blocking test [iotdb]
Posted by "Caideyipi (via GitHub)" <gi...@apache.org>.
Caideyipi commented on PR #18364:
URL: https://github.com/apache/iotdb/pull/18364#issuecomment-6413795140
Self-review passed for `fb6a0eaf46885361cc1ee3688884b8ac91cccc98`.
Reviewed the complete diff, the blocking/wakeup logic in `IndexedBlockingQueue.poll()` and `push()`, the Awaitility dependency, and the sibling L2/multilevel queue tests. The bounded condition waits preserve the blocking and completion assertions while removing the fixed-sleep scheduling race. No actionable issues were found; no fixes were needed.
Validation:
- `git diff --check` passed.
- Existing GitHub Actions CI for this exact PR head passed on [Ubuntu](https://github.com/apache/iotdb/actions/runs/30534388780/job/90844040954) and [Windows](https://github.com/apache/iotdb/actions/runs/30534388780/job/90844040944). Both job logs confirm `L1PriorityQueueTest`: 5 tests, 0 failures, 0 errors, 0 skipped.
- No new build or test run was performed during this review.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org