apache / apache/pulsar

Flaky-test: ConsumerBatchReceiveTest.testBatchReceiveAndRedeliveryNonPartitionedTopic

Open
#17,593 1 comment 0 reactions 0 assignees View on GitHub
area/test Stale type/flaky-tests
Dominant language
Java
Stars
15.3k
Forks
3.8k
Avg merge
1d 14h
Merged PRs (30d)
160

Description

### Search before asking

- [X] I searched in the [issues](https://github.com/apache/pulsar/issues) and found nothing similar.

### Example failure

https://github.com/apache/pulsar/runs/8306845946?check_suite_focus=true#step:10:1324

### Exception stacktrace

Full exception stacktrace

  Error:  Tests run: 204, Failures: 7, Errors: 0, Skipped: 83, Time elapsed: 241.006 s <<< FAILURE! - in org.apache.pulsar.client.api.ConsumerBatchReceiveTest

Error: testBatchReceiveAndRedeliveryNonPartitionedTopic(org.apache.pulsar.client.api.ConsumerBatchReceiveTest) Time elapsed: 4.618 s <<< FAILURE!
java.lang.AssertionError: expected [202] but found [200]
at org.testng.Assert.fail(Assert.java:99)
at org.testng.Assert.failNotEquals(Assert.java:1037)
at org.testng.Assert.assertEqualsImpl(Assert.java:140)
at org.testng.Assert.assertEquals(Assert.java:122)
at org.testng.Assert.assertEquals(Assert.java:907)
at org.testng.Assert.assertEquals(Assert.java:917)
at org.apache.pulsar.client.api.ConsumerBatchReceiveTest.batchReceiveAndRedelivery(ConsumerBatchReceiveTest.java:648)
at org.apache.pulsar.client.api.ConsumerBatchReceiveTest.testBatchReceiveAndRedelivery(ConsumerBatchReceiveTest.java:564)
at org.apache.pulsar.client.api.ConsumerBatchReceiveTest.testBatchReceiveAndRedeliveryNonPartitionedTopic(ConsumerBatchReceiveTest.java:382)
at jdk.internal.reflect.GeneratedMethodAccessor714.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:568)
at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
at org.testng.internal.InvokeMethodRunnable.runOne(InvokeMethodRunnable.java:45)
at org.testng.internal.InvokeMethodRunnable.call(InvokeMethodRunnable.java:73)
at org.testng.internal.InvokeMethodRunnable.call(InvokeMethodRunnable.java:11)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:833)

### Are you willing to submit a PR?

- [ ] I'm willing to submit a PR!

Contributor guide

Open the contributing guide

Research direction

Start with org.apache.pulsar.client.api.ConsumerBatchReceiveTest, especially testBatchReceiveAndRedeliveryNonPartitionedTopic and batchReceiveAndRedelivery around lines 382, 564, and 648. Run the targeted test repeatedly and investigate why the redelivery assertion sometimes finds 200 messages instead of 202. Done means the test reliably passes while still checking batch receive and redelivery behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
distributed-systems, testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.