fix(tests): stabilize TQEClusterIntegrationTest against queue dedup#104
Draft
dkasimovskiy wants to merge 2 commits into
Draft
fix(tests): stabilize TQEClusterIntegrationTest against queue dedup#104dkasimovskiy wants to merge 2 commits into
dkasimovskiy wants to merge 2 commits into
Conversation
The TQE queue config (both 2.x and 3.x) sets deduplication_mode: keep_latest, so duplicate (age, name) payloads collapse on the broker. The previous Instancio generator with allowEmpty().nullable() names periodically produced collisions (1 in ~30 runs), leaving the consumer unable to ever receive USERS_COUNT messages and timing out at 60s. Generate strictly-unique deterministic users so dedup is a no-op. Also subscribe before publishing so the consumer stream is active when messages are produced, avoiding reliance on cursor="" replay while the broker is settling. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
subscribe() returns void immediately after kicking off the async stream, so retryUntilSuccess cannot retry a failure — the wrapper is dead weight. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
5980ade to
8b3a02d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
TQEClusterIntegrationTest.testPublishAndConsumeData(both TQE 2.x and 3.x parameters) intermittently timed out at 60s waiting for the consumer to receive 100 messages.deduplication_mode: keep_latest, so duplicate(age, name)payloads collapse on the broker. The previous Instancio generator (allowEmpty().nullable()names, full int range ages) periodically produced collisions (~1 in 30 runs locally), leaving the consumer unable to ever reach 100 messages.User(i, "user-"+i)so dedup is a no-op. Also subscribe before publishing so the consumer stream is active when messages are produced.I haven't forgotten about:
🤖 Generated with Claude Code