Skip to content

[fix][test] Fix flaky PersistentTopicTerminateTest.testRecoverAfterTerminate#25345

Open
merlimat wants to merge 1 commit intoapache:masterfrom
merlimat:fix/flaky-PersistentTopicTerminateTest
Open

[fix][test] Fix flaky PersistentTopicTerminateTest.testRecoverAfterTerminate#25345
merlimat wants to merge 1 commit intoapache:masterfrom
merlimat:fix/flaky-PersistentTopicTerminateTest

Conversation

@merlimat
Copy link
Contributor

@merlimat merlimat commented Mar 17, 2026

Flaky test failure

org.awaitility.core.ConditionTimeoutException: Assertion condition expected [true] but found [false] within 10 seconds.
	at org.apache.pulsar.client.api.PersistentTopicTerminateTest.testRecoverAfterTerminate

Summary

  • Fix flaky PersistentTopicTerminateTest.testRecoverAfterTerminate by increasing the Awaitility timeout from 10s (default) to 30s.
  • The ledger trim operation after topic termination involves metadata store operations that may not complete within 10s under load.

Documentation

  • doc-not-needed
    (Your PR doesn't need any doc update)

Matching PR in forked repository

No response

Tip

Add the labels ready-to-test and area/test to trigger the CI.

@github-actions github-actions bot added the doc-not-needed Your PR changes do not impact docs label Mar 17, 2026
@merlimat merlimat marked this pull request as draft March 17, 2026 23:24
…rminate

The test called skipAllMessages to advance the cursor but the
consumer had already received the messages without acknowledging
them. The skipAllMessages call can race with the consumer's internal
state. Use acknowledgeCumulative on the last message instead, which
properly advances the mark-delete position. Also increase the
Awaitility timeout to 30s for the ledger trim.
@merlimat merlimat force-pushed the fix/flaky-PersistentTopicTerminateTest branch from 92a8472 to 5132522 Compare March 17, 2026 23:26
@merlimat merlimat marked this pull request as ready for review March 17, 2026 23:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/test doc-not-needed Your PR changes do not impact docs ready-to-test

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant