Skip to content

8302858: Polish FlightRecorderMXBeanImpl #12656

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

Closed
wants to merge 4 commits into from

Conversation

minborg
Copy link
Contributor

@minborg minborg commented Feb 20, 2023

This PR proposes some polishing of the FlightRecorderMXBeanImpl class.


Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issue

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/12656/head:pull/12656
$ git checkout pull/12656

Update a local copy of the PR:
$ git checkout pull/12656
$ git pull https://git.openjdk.org/jdk pull/12656/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 12656

View PR using the GUI difftool:
$ git pr show -t 12656

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/12656.diff

@bridgekeeper
Copy link

bridgekeeper bot commented Feb 20, 2023

👋 Welcome back pminborg! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot added the rfr Pull request is ready for review label Feb 20, 2023
@openjdk
Copy link

openjdk bot commented Feb 20, 2023

@minborg The following label will be automatically applied to this pull request:

  • hotspot-jfr

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the hotspot-jfr hotspot-jfr-dev@openjdk.org label Feb 20, 2023
@mlbridge
Copy link

mlbridge bot commented Feb 20, 2023

Webrevs

@@ -303,12 +303,12 @@ public void setRecordingOptions(long recording, Map<String, String> options) thr
validateOption(ops, OPTION_DESTINATION, x -> MBeanUtils.destination(r, x));

// All OK, now set them.atomically
Copy link
Contributor

Choose a reason for hiding this comment

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

As this is a tidyup, could we remove the dot from "them.atomically" which is a typo.
I didn't see what was atomic at first. If all options are valid, we set them all, which is great, but not really atomic. Could just remove the word "atomically"?

@@ -282,14 +282,14 @@ public void setRecordingOptions(long recording, Map<String, String> options) thr
for (Map.Entry<String, String> entry : ops.entrySet()) {
Object key = entry.getKey();
Object value = entry.getValue();
if (!(key instanceof String)) {
throw new IllegalArgumentException("Option key must not be null, or other type than " + String.class);
Copy link
Member

Choose a reason for hiding this comment

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

Why is the type check removed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because it must be a String as we are iterating over Map.Entry<String, String>

Copy link
Member

Choose a reason for hiding this comment

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

Only at compile time. A user could send data over the network using other types.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for clarifying this. I have reverted accordingly.

@openjdk
Copy link

openjdk bot commented Feb 20, 2023

@minborg This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8302858: Polish FlightRecorderMXBeanImpl

Reviewed-by: egahlin

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 18 new commits pushed to the master branch:

  • 0bf3a53: 8302599: Extend ASan support to Microsoft Visual C++
  • c7517b3: 8302525: Write a test to check various components send Events while mouse and key are used simultaneously
  • 9a79722: 8299234: JMX Repository.query performance
  • e47e9ec: 8300658: memory_and_swap_limit() reporting wrong values on systems with swapaccount=0
  • 7cf7e0a: 8302070: Factor null-check into load_klass() calls
  • e731695: 8302882: Newly added test javax/swing/JFileChooser/JFileChooserFontReset.java fails with HeadlessException
  • b5a7426: 8301749: Tracking malloc pooled memory size
  • 6ac5e05: 8302068: Serial: Refactor oop closures used in Young GC
  • 71cf7c4: 8302518: Add missing Op_RoundDoubleMode in VectorNode::vector_operands()
  • 98716e2: 8302709: Remove explicit remembered set verification in G1
  • ... and 8 more: https://git.openjdk.org/jdk/compare/432cf68c4dd1dcce478fccb85163aa0d824474d7...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Feb 20, 2023
@kevinjwalls
Copy link
Contributor

Updates look good 8-)

@minborg
Copy link
Contributor Author

minborg commented Feb 22, 2023

/integrate

@openjdk
Copy link

openjdk bot commented Feb 22, 2023

Going to push as commit 861eea9.
Since your change was applied there have been 58 commits pushed to the master branch:

  • 60a3581: 8302856: Typo in FlightRecorderMXBeanImpl
  • 3f3a1f5: 8302815: Use new Math.clamp method in core libraries
  • 5e1d1b7: 8302870: More information needed from failures in vmTestbase ThreadUtils.waitThreadState
  • 7f35389: 8302888: containers/docker/TestJcmd.java fails when run as root under podman
  • b6ecca1: 8280113: (dc) DatagramSocket.receive does not always throw when the channel is closed
  • f54e108: 8302831: PPC: compiler/codecache/TestStressCodeBuffers.java fails after JDK-8301819
  • cba817a: 8302838: jabswitch main() should avoid calling exit explicitly
  • 2c52cf0: 8041447: Test javax/swing/dnd/7171812/bug7171812.java fails with java.lang.RuntimeException: Test failed, scroll on drag doesn't work
  • 180b94c: 8302907: [PPC64] Use more constexpr in class Register
  • f319c92: 8303016: Invalid escapes in grep patterns
  • ... and 48 more: https://git.openjdk.org/jdk/compare/432cf68c4dd1dcce478fccb85163aa0d824474d7...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Feb 22, 2023
@openjdk openjdk bot closed this Feb 22, 2023
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Feb 22, 2023
@openjdk
Copy link

openjdk bot commented Feb 22, 2023

@minborg Pushed as commit 861eea9.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hotspot-jfr hotspot-jfr-dev@openjdk.org integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

3 participants