BulkheadAsynchRetryTest.testRetriesJoinBackOfQueue seems wrong
See original GitHub issueMy reading of the test BulkheadAsynchRetryTest.testRetriesJoinBackOfQueue
suggests that it’s implementation-dependent. That is, I believe it’s possible to write an compliant implementation that fails this test. I’m specifically thinking:
- The beginning of the test reads:
AsyncBulkheadTask taskA = newTask();
Future resultA = retryQueueAsyncBean.test(taskA);
AsyncBulkheadTask taskB = newTask();
Future resultB = retryQueueAsyncBean.test(taskB);
AsyncBulkheadTask taskC = newTask();
Future resultC = retryQueueAsyncBean.test(taskC);
taskA.assertStarting(resultA);
taskB.assertNotStarting();
taskC.assertNotStarting();
This test expects the first call will be the first to make it into the bulkhead, while there’s nothing in the test that would affect thread ordering. Clearly this presumes one implementation strategy, while other implementation strategies are also valid.
- The test javadoc also says
Test that when an execution is retried, it goes to the back of the bulkhead queue.
This itself again presumes an implementation strategy, while there are other valid implementation strategies.
WDYT?
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:6 (6 by maintainers)
Top Results From Across the Web
No results found
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ll submit a PR.
I forgot to mention the issue number in the PR, but this has been resolved in #410.