You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Isolates the Kafka Connect source and sink instrumentation tests on separate topics.
Waits for the exact tagged producer-to-consumer data-stream pathway instead of assuming that any two recorded groups form the expected chain.
Motivation
GitLab job 1915544954 exposed a flaky sink instrumentation test. The shared topic retained the source test's record, so the sink connector could consume that stale record before the newly produced one. waitForGroups(2) then returned with a current producer group and an unrelated consumer group, causing the expected child lookup to return null.
Test failed with:
org.spockframework.runtime.SpockAssertionError: Target of 'verifyAll' block must not be null
Target of 'verifyAll' block must not be null
at spock.lang.Specification.verifyAll(Specification.java:286)
at ConnectWorkerInstrumentationTest.test kafka-connect sink instrumentation(ConnectWorkerInstrumentationTest.groovy:296)
And later passed via Develocity Gradle plugin retry.
The reason will be displayed to describe this comment to others. Learn more.
More details
Topic isolation prevents the source record from contaminating the sink case, while the exact pathway lookup correctly ignores stale topics and competing consumer groups and returns the intended producer-to-consumer chain.
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
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.
What Does This Do
Motivation
GitLab job 1915544954 exposed a flaky sink instrumentation test. The shared topic retained the source test's record, so the sink connector could consume that stale record before the newly produced one.
waitForGroups(2)then returned with a current producer group and an unrelated consumer group, causing the expected child lookup to returnnull.Test failed with:
And later passed via Develocity Gradle plugin retry.
Additional Notes
Validation:
./gradlew :dd-java-agent:instrumentation:kafka:kafka-connect-0.11:test --tests 'ConnectWorkerInstrumentationTest' -PtestJvm=11 --rerun-tasks./gradlew :dd-java-agent:instrumentation:kafka:kafka-connect-0.11:spotlessCheckRelevant precedent PRs: none.
Contributor Checklist
type:and (comp:orinst:) labels in addition to any other useful labelsclose,fix, or any linking keywords when referencing an issueUse
solvesinstead, and assign the PR milestone to the issueJira ticket: N/A