jdk icon indicating copy to clipboard operation
jdk copied to clipboard

8290036: Define and specify Runtime shutdown sequence

Open stuart-marks opened this issue 2 years ago • 7 comments

The concept of the shutdown sequence needs to be specified more clearly. This PR adds text for this into the class specification of java.lang.Runtime. Also includes adjustments to related areas in addShutdownHook, halt, and in the System and Thread classes. The changes here should coordinate with similar changes to JLS 12.8, JVMS 5.7, and the Invocation API chapter of the JNI Specification.


Progress

  • [x] Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • [x] Change must not contain extraneous whitespace
  • [x] Commit message must refer to an issue
  • [ ] Change requires a CSR request to be approved

Issue

  • JDK-8290036: Define and specify Runtime shutdown sequence

Reviewers

Reviewing

Using git

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

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

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 9437

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

Using diff file

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

stuart-marks avatar Jul 08 '22 23:07 stuart-marks

:wave: Welcome back smarks! 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.

bridgekeeper[bot] avatar Jul 08 '22 23:07 bridgekeeper[bot]

@stuart-marks The following label will be automatically applied to this pull request:

  • core-libs

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[bot] avatar Jul 08 '22 23:07 openjdk[bot]

Sorry David I should have clarified this a bit. The changes currently in this draft PR are merely what occurred to Alex and me while we were working on JLS 12.8. There are a bunch of other issues that need to be covered or at clarified clarified here, or possibly in the Runtime class specification. I'll add them to the bug report, and eventually we'll update this PR with further changes.

stuart-marks avatar Jul 13 '22 16:07 stuart-marks

Discussion of the changes in this PR are taking place in the bug report:

https://bugs.openjdk.org/browse/JDK-8290036

stuart-marks avatar Jul 15 '22 21:07 stuart-marks

/csr

stuart-marks avatar Aug 03 '22 00:08 stuart-marks

@stuart-marks has indicated that a compatibility and specification (CSR) request is needed for this pull request.

@stuart-marks please create a CSR request for issue JDK-8290036 with the correct fix version. This pull request cannot be integrated until the CSR request is approved.

openjdk[bot] avatar Aug 03 '22 00:08 openjdk[bot]

OK, I finally got back to this. I incorporated most suggested edits. Please re-review.

stuart-marks avatar Sep 30 '22 21:09 stuart-marks

CSR drafted, please review:

https://bugs.openjdk.org/browse/JDK-8294817

stuart-marks avatar Oct 05 '22 04:10 stuart-marks

/integrate

stuart-marks avatar Oct 05 '22 23:10 stuart-marks

@stuart-marks This pull request has not yet been marked as ready for integration.

openjdk[bot] avatar Oct 05 '22 23:10 openjdk[bot]

@stuart-marks 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:

8290036: Define and specify Runtime shutdown sequence

Reviewed-by: dholmes, alanb

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

  • 0ec18382b74396eec0681f2fdf0dac40f8fe108b: 8294869: Correct failure of RemovedJDKInternals.java after JDK-8294618
  • 87acfee3c3e8dbc36b87e449f69fda6fca0088f6: 8294397: Replace StringBuffer with StringBuilder within java.text
  • f2c57186a40bea4d5ad1c3ba010b59e552db624d: 8294734: Redundant override in AES implementation
  • 536c9a512ea90d97a1ae5310453410d55db98bdd: 8294618: Update openjdk.java.net => openjdk.org
  • f531dae4a0ffd2a5663cf4a4bde581d68fc728d5: 8294840: langtools OptionalDependencyTest.java use File.pathSeparator
  • ee6c39175bc47608282c52c575ce908399349e7c: 8289925: Shared code shouldn't reference the platform specific method frame::interpreter_frame_last_sp()
  • bd90c4cfa63ba2de26f7482ed5d1704f9be9629f: 8282900: runtime/stringtable/StringTableCleaningTest.java verify unavailable at this moment
  • 979efd4174968802f0c170e768671507a11e118e: 8289004: investigate if SharedRuntime::get_java_tid parameter should be a JavaThread*
  • b9eeec2b6b8f97d2ba33462b27d091f918067f78: 8294310: compare.sh fails on macos after JDK-8293550
  • 13a5000d4885d4624788580f56634b93a135429b: 8294151: JFR: Unclear exception message when dumping stopped in memory recording
  • ... and 7 more: https://git.openjdk.org/jdk/compare/1dafbe3f944fdb3027df38a886fd15abc3b476a7...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[bot] avatar Oct 05 '22 23:10 openjdk[bot]

I guess I got into a race with the bot and lost. Retrying.

/integrate

stuart-marks avatar Oct 05 '22 23:10 stuart-marks

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

  • 0ec18382b74396eec0681f2fdf0dac40f8fe108b: 8294869: Correct failure of RemovedJDKInternals.java after JDK-8294618
  • 87acfee3c3e8dbc36b87e449f69fda6fca0088f6: 8294397: Replace StringBuffer with StringBuilder within java.text
  • f2c57186a40bea4d5ad1c3ba010b59e552db624d: 8294734: Redundant override in AES implementation
  • 536c9a512ea90d97a1ae5310453410d55db98bdd: 8294618: Update openjdk.java.net => openjdk.org
  • f531dae4a0ffd2a5663cf4a4bde581d68fc728d5: 8294840: langtools OptionalDependencyTest.java use File.pathSeparator
  • ee6c39175bc47608282c52c575ce908399349e7c: 8289925: Shared code shouldn't reference the platform specific method frame::interpreter_frame_last_sp()
  • bd90c4cfa63ba2de26f7482ed5d1704f9be9629f: 8282900: runtime/stringtable/StringTableCleaningTest.java verify unavailable at this moment
  • 979efd4174968802f0c170e768671507a11e118e: 8289004: investigate if SharedRuntime::get_java_tid parameter should be a JavaThread*
  • b9eeec2b6b8f97d2ba33462b27d091f918067f78: 8294310: compare.sh fails on macos after JDK-8293550
  • 13a5000d4885d4624788580f56634b93a135429b: 8294151: JFR: Unclear exception message when dumping stopped in memory recording
  • ... and 7 more: https://git.openjdk.org/jdk/compare/1dafbe3f944fdb3027df38a886fd15abc3b476a7...master

Your commit was automatically rebased without conflicts.

openjdk[bot] avatar Oct 05 '22 23:10 openjdk[bot]

@stuart-marks Pushed as commit d4142d8441172fc54c9abf0a735c30b0ac8638c5.

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

openjdk[bot] avatar Oct 05 '22 23:10 openjdk[bot]