Repository navigation
Conversation
Co-authored-by: cgcote <5115638+cgcote@users.noreply.github.com>
Contributor
🟢 Java Benchmark SLOs — All performance SLOs passed
PR vs. master results
Commit: Load and DaCapo benchmarks can be triggered manually in the GitLab pipeline. Results will appear in the Benchmarking Platform UI after completion. |
This branch has not been deployed
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.
What Does This Do
Makes
SmapEntryCacheTest.preservesMixedPathEncodingsInRecording()read thepathnamefield only fromSmapEntryEventevents in the dumped JFR recording. Other event types in the dump are skipped. The exact assertion on the two expected pathnames and their order is unchanged. This is a test-only change.Motivation
Root cause: The test went through every event in the
RecordingFileand calledgetString("pathname")on each one. A JFR dump is not limited to the events enabled on the test's ownRecording. When another recording is active in the same JVM (for example, one started by other profiling tests in the module), the dump also contains other event types, such asjdk.ActiveRecordingandjdk.ActiveSetting. Those events have nopathnamefield, so the test fails with:The fix compares each event's type name with
EventType.getEventType(SmapEntryEvent.class).getName()before readingpathname. This removes the cause instead of making it less likely.Impact (Datadog Flaky Test Management):
com.datadog.profiling.controller.openjdk.events.SmapEntryCacheTest.preservesMixedPathEncodingsInRecording().7de157655f1cf613. Attempt-to-fix ID:FBPWT2(DD_FBPWT2).Additional Notes
Testing (run in the Bits Code session, as reported by the session):
./gradlew :dd-java-agent:agent-profiling:profiling-controller-openjdk:test --tests 'com.datadog.profiling.controller.openjdk.events.SmapEntryCacheTest': 15 cases passed. Two more--rerunruns also passed 15/15../gradlew :dd-java-agent:agent-profiling:profiling-controller-openjdk:test --rerun(full module): 48 passed, 2 skipped, 0 failures../gradlew :dd-java-agent:agent-profiling:profiling-controller-openjdk:spotlessCheck: passed.Risks: Very low. The change only touches one test method, and there are no production code changes. There are no sleeps, timeout changes, relaxed assertions or quarantines.
Prepared in Bits Code session: https://app.datadoghq.com/code/9cbc641e-f72d-4721-a995-ecb481b53708
This PR was opened by the dd-trace Flaky-Test ROI Recommender via Bits Code.
Contributor Checklist
type: bug,comp: profiling,tag: ai generatedandtag: no release notes(test-only).Jira ticket: N/A
PR by Bits - View session in Datadog
Comment @DataDog to request changes