Skip to content

Mark Kafka DSM disabled batch consume test flaky for parentId mismatch#10795

Closed
bm1549 wants to merge 1 commit intomasterfrom
brian.marks/fix-kafka-dsm-disabled-flaky-test
Closed

Mark Kafka DSM disabled batch consume test flaky for parentId mismatch#10795
bm1549 wants to merge 1 commit intomasterfrom
brian.marks/fix-kafka-dsm-disabled-flaky-test

Conversation

@bm1549
Copy link
Copy Markdown
Contributor

@bm1549 bm1549 commented Mar 10, 2026

What Does This Do

Updates the @Flaky annotation on test spring kafka template produce and batch consume in KafkaClientTestBase to document the consumer span parentId mismatch failure mode in addition to the previously documented partition ordering issue.

Motivation

The test KafkaClientDataStreamsDisabledForkedTesttest spring kafka template produce and batch consume was observed failing in CI with:

assert span.parentId == parent.spanId

This failure occurs because the else branch of the assertTraces block (used when hasQueueSpan() is false) assumes a deterministic mapping between consumer trace ordering and producer span indices within trace(0). Since SORT_TRACES_BY_ID uses random trace IDs, the consumer-to-producer linkage is non-deterministic.

The test was already annotated @Flaky for a related partition-ordering issue (#3864). This PR updates the annotation message to accurately describe all known failure modes from this same root cause.

Additional Notes

  • Failure rate: 1x in 30 days
  • The root cause (non-deterministic batch consumer trace ordering) is the same as the existing @Flaky issue
  • No functional code changes; this is a test annotation update only

Contributor Checklist

Jira ticket: N/A

…atch

The test "test spring kafka template produce and batch consume" was already
annotated @flaky for partition ordering issues. Update the annotation to
also document the consumer span parentId mismatch failure mode that occurs
due to non-deterministic trace ordering in KafkaClientDataStreamsDisabledForkedTest.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@bm1549 bm1549 added tag: flaky test Flaky tests type: bug Bug report and fix inst: others All other instrumentations tag: no release notes Changes to exclude from release notes labels Mar 10, 2026
@bm1549
Copy link
Copy Markdown
Contributor Author

bm1549 commented Mar 10, 2026

Closing — need to fix the non-deterministic consumer→producer trace mapping rather than update @flaky message

@bm1549 bm1549 closed this Mar 10, 2026
@ygree
Copy link
Copy Markdown
Contributor

ygree commented Apr 21, 2026

Addressed in #11168

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

inst: others All other instrumentations tag: flaky test Flaky tests tag: no release notes Changes to exclude from release notes type: bug Bug report and fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants