Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added JavaFlightRecorder options for Tests #3098

Merged
merged 1 commit into from Aug 25, 2023

Conversation

AndreasTu
Copy link
Contributor

This allows you to create JFR recordings with the flag -Pjfr when running Gradle Test tasks.

The jfr_config.jfc provides a profiling config for the JFR. It tracks the TLAB allocations in addition to the normal profiling config in JDKs (JDK/lib/jfr/profile.jfc). It has also the following changes:

  • Method sampling interval of 2 ms
  • Thread dump interval of 10 s
  • CompilerInlining true
  • ObjectAllocationSample throttle 1000/s
  • JavaExceptionThrow true

Checklist

  • Read the contributing guide
  • PR should be motivated, i.e. what does it fix, why, and if relevant how
  • If possible / relevant include an example in the description, that could help all readers
    including project members to get a better picture of the change
  • Avoid other runtime dependencies
  • Meaningful commit history ; intention is important please rebase your commit history so that each
    commit is meaningful and help the people that will explore a change in 2 years
  • The pull request follows coding style
  • Mention Fixes #<issue number> in the description if relevant
  • At least one commit should mention Fixes #<issue number> if relevant

This allows you to create JFR recordings with the flag -Pjfr
when running Gradle Test tasks.

The jfr_config.jfc provides a profiling config for the JFR.
It tracks the TLAB allocations in addition to the normal
profiling config in JDKs (JDK/lib/jfr/profile.jfc).
It has also the following changes:
 * Method sampling interval of 2 ms
 * Thread dump  interval of 10 s
 * CompilerInlining true
 * ObjectAllocationSample throttle 1000/s
 * JavaExceptionThrow true
@AndreasTu
Copy link
Contributor Author

@TimvdLippe This is the JFR PR.

@codecov-commenter
Copy link

codecov-commenter commented Aug 22, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +73.06% 🎉

Comparison is base (076e8ac) 12.39% compared to head (755bbf8) 85.45%.
Report is 1 commits behind head on main.

Additional details and impacted files
@@              Coverage Diff              @@
##               main    #3098       +/-   ##
=============================================
+ Coverage     12.39%   85.45%   +73.06%     
- Complexity      422     2889     +2467     
=============================================
  Files           329      329               
  Lines          8813     8822        +9     
  Branches       1094     1095        +1     
=============================================
+ Hits           1092     7539     +6447     
+ Misses         7510      995     -6515     
- Partials        211      288       +77     
Files Changed Coverage Δ
...eation/bytebuddy/TypeCachingBytecodeGenerator.java 81.13% <100.00%> (+35.67%) ⬆️

... and 299 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@TimvdLippe TimvdLippe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@TimvdLippe TimvdLippe merged commit eeeff29 into mockito:main Aug 25, 2023
13 checks passed
@AndreasTu AndreasTu deleted the JavaFlightRecorder branch August 25, 2023 18:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants