Commit 4a2577b
authored
KAFKA-17395 Flaky test testMissingOffsetNoResetPolicy for new consumer (apache#17056)
In AsyncKafkaConsumer, FindCoordinatorRequest is sent by background thread. In MockClient#prepareResponseFrom, it only matches the response to a future request. If there is some race condition, FindCoordinatorResponse may not match to a FindCoordinatorRequest. It's better to put MockClient#prepareResponseFrom before the request to avoid flaky test.
Reviewers: TaiJuWu <[email protected]>, Chia-Ping Tsai <[email protected]>1 parent 3efa785 commit 4a2577b
File tree
1 file changed
+4
-6
lines changed- clients/src/test/java/org/apache/kafka/clients/consumer
1 file changed
+4
-6
lines changedLines changed: 4 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
924 | 924 | | |
925 | 925 | | |
926 | 926 | | |
927 | | - | |
928 | | - | |
929 | | - | |
930 | | - | |
931 | 927 | | |
932 | 928 | | |
933 | | - | |
934 | | - | |
935 | 929 | | |
936 | 930 | | |
| 931 | + | |
| 932 | + | |
| 933 | + | |
| 934 | + | |
937 | 935 | | |
938 | 936 | | |
939 | 937 | | |
| |||
0 commit comments