Skip to content

8317920: JDWP-agent sends broken exception event with onthrow option #2206

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

Conversation

parttimenerd
Copy link
Contributor

@parttimenerd parttimenerd commented Oct 23, 2023

Fixes the bug that is in the JDWP-agent since JDK 1.5.

The original patch did not apply cleanly because Virtual Threads and instanceof patterns are not present in JDK 11 and the Debuggee class changed slightly.

Tested on Mac M1 with the added test case, the code is platform-independent.


Progress

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

Issue

  • JDK-8317920: JDWP-agent sends broken exception event with onthrow option (Bug - P4 - Approved) ⚠️ Issue is already resolved. Consider making this a "backport pull request" by setting the PR title to Backport <hash> with the hash of the original commit. See Backports.

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk11u-dev.git pull/2206/head:pull/2206
$ git checkout pull/2206

Update a local copy of the PR:
$ git checkout pull/2206
$ git pull https://git.openjdk.org/jdk11u-dev.git pull/2206/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 2206

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

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk11u-dev/pull/2206.diff

Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Oct 23, 2023

👋 Welcome back jbechberger! 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 approval rfr Pull request is ready for review labels Oct 23, 2023
@mlbridge
Copy link

mlbridge bot commented Oct 23, 2023

Webrevs

@openjdk
Copy link

openjdk bot commented Oct 25, 2023

⚠️ @parttimenerd This change is now ready for you to apply for maintainer approval. This can be done directly in each associated issue or by using the /approval command.

@phohensee
Copy link
Member

The GHA build failures are puzzling because the code in debugInit.c that causes the failure doesn't exist in the jdk11u-dev version.

@parttimenerd parttimenerd force-pushed the parttimenerd-backport-8f4ebd89 branch from d322be4 to dc4ce82 Compare November 2, 2023 11:47
@openjdk
Copy link

openjdk bot commented Nov 2, 2023

@parttimenerd Please do not rebase or force-push to an active PR as it invalidates existing review comments. Note for future reference, the bots always squash all changes into a single commit automatically as part of the integration. See OpenJDK Developers’ Guide for more information.

@parttimenerd
Copy link
Contributor Author

The GHA build failures are puzzling because the code in debugInit.c that causes the failure doesn't exist in the jdk11u-dev version.

And it builds on some architectures, despite being platform-independent.

@GoeLin
Copy link
Member

GoeLin commented Nov 2, 2023

threadControl_onEventHandlerEntry(...) has different args in 11 and 17. The fact that it compiled is just luck probably.

@parttimenerd
Copy link
Contributor Author

Thank you, I'll fix it tomorrow.

@parttimenerd
Copy link
Contributor Author

It works now :)

@tstuefe
Copy link
Member

tstuefe commented Nov 7, 2023

Hi @parttimenerd, did this run through the SAP 11u tests?

@parttimenerd
Copy link
Contributor Author

Yes, last night and without any issues (as far I can ascertain).

@GoeLin
Copy link
Member

GoeLin commented Nov 7, 2023

/approve yes

@openjdk
Copy link

openjdk bot commented Nov 7, 2023

@GoeLin
8317920: The approval request has been approved.

@openjdk
Copy link

openjdk bot commented Nov 7, 2023

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

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

8317920: JDWP-agent sends broken exception event with onthrow option

Reviewed-by: phh

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 16 new commits pushed to the master branch:

  • b64a1ac: 8293166: jdk/jfr/jvm/TestDumpOnCrash.java fails on Linux ppc64le and Linux aarch64
  • 80d3bb4: 8289745: JfrStructCopyFailed uses heap words instead of bytes for object sizes
  • 1f67ffb: 8318669: Target OS detection in 'test-prebuilt' makefile target is incorrect when running on MSYS2
  • f6bdbe8: 8317967: Enhance test/jdk/javax/net/ssl/TLSCommon/SSLEngineTestCase.java to handle default cases
  • feb051f: 8316906: Clarify TLABWasteTargetPercent flag
  • 9abfdde: 8314063: The socket is not closed in Connection::createSocket when the handshake failed for LDAP connection
  • 18d616d: 8306280: Open source several choice AWT tests
  • f993ef5: 8284331: Add sanity check for signal handler modification warning.
  • 92c5062: 8289238: Refactoring changes to PassFailJFrame Test Framework
  • d90b9ac: 8285612: Remove jtreg tag manual=yesno for java/awt/print/PrinterJob/ImagePrinting/ClippedImages.java
  • ... and 6 more: https://git.openjdk.org/jdk11u-dev/compare/de9ae1eac41876c2995e99256225085297171048...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.

As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@phohensee) but any other Committer may sponsor as well.

➡️ To flag this PR as ready for integration with the above commit message, type /integrate in a new comment. (Afterwards, your sponsor types /sponsor in a new comment to perform the integration).

@openjdk openjdk bot added ready Pull request is ready to be integrated and removed approval labels Nov 7, 2023
@tstuefe
Copy link
Member

tstuefe commented Nov 7, 2023

Yes, last night and without any issues (as far I can ascertain).

Thank you!

@parttimenerd
Copy link
Contributor Author

/integrate

@openjdk openjdk bot added the sponsor Pull request is ready to be sponsored label Nov 7, 2023
@openjdk
Copy link

openjdk bot commented Nov 7, 2023

@parttimenerd
Your change (at version cb034b8) is now ready to be sponsored by a Committer.

@GoeLin
Copy link
Member

GoeLin commented Nov 7, 2023

/sponsor

@openjdk
Copy link

openjdk bot commented Nov 7, 2023

Going to push as commit 662f3bd.
Since your change was applied there have been 22 commits pushed to the master branch:

  • 68807aa: 8314242: Update applications/scimark/Scimark.java to accept VM flags
  • 5754eb1: 8290469: Add new positioning options to PassFailJFrame test framework
  • 2aca53f: 8026393: jarsigner never shows a warning in badKeyUsage case
  • ff19eeb: 8285687: Remove jtreg tag manual=yesno for java/awt/print/PrinterJob/PageRangesDlgTest.java
  • 2f3fc25: 8232135: Add diagnostic output to test java/util/ProcessBuilder/Basic.java
  • 48f1f39: 8230435: Replace wildcard address with loopback or local host in tests - part 22
  • b64a1ac: 8293166: jdk/jfr/jvm/TestDumpOnCrash.java fails on Linux ppc64le and Linux aarch64
  • 80d3bb4: 8289745: JfrStructCopyFailed uses heap words instead of bytes for object sizes
  • 1f67ffb: 8318669: Target OS detection in 'test-prebuilt' makefile target is incorrect when running on MSYS2
  • f6bdbe8: 8317967: Enhance test/jdk/javax/net/ssl/TLSCommon/SSLEngineTestCase.java to handle default cases
  • ... and 12 more: https://git.openjdk.org/jdk11u-dev/compare/de9ae1eac41876c2995e99256225085297171048...master

Your commit was automatically rebased without conflicts.

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

openjdk bot commented Nov 7, 2023

@GoeLin @parttimenerd Pushed as commit 662f3bd.

💡 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
integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

4 participants