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

8274079: Cleanup unnecessary calls to Throwable.initCause() in java.base module #5551

Conversation

turbanoff
Copy link
Member

@turbanoff turbanoff commented Sep 16, 2021

Pass "cause" exception as constructor parameter is shorter and easier to read.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8274079: Cleanup unnecessary calls to Throwable.initCause() in java.base module

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk pull/5551/head:pull/5551
$ git checkout pull/5551

Update a local copy of the PR:
$ git checkout pull/5551
$ git pull https://git.openjdk.java.net/jdk pull/5551/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 5551

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

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk/pull/5551.diff

…se module

Pass cause exception as constructor parameter is shorter and easier to read.
@bridgekeeper
Copy link

@bridgekeeper bridgekeeper bot commented Sep 16, 2021

👋 Welcome back turbanoff! 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
Copy link

@openjdk openjdk bot commented Sep 16, 2021

@turbanoff The following labels will be automatically applied to this pull request:

  • core-libs
  • net
  • security

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

@openjdk openjdk bot added security core-libs net labels Sep 16, 2021
@turbanoff turbanoff changed the title [PATCH] Cleanup unnecessary calls to Throwable.initCause() in java.base module 8274079: Cleanup unnecessary calls to Throwable.initCause() in java.base module Sep 21, 2021
@openjdk openjdk bot added the rfr label Sep 21, 2021
@mlbridge
Copy link

@mlbridge mlbridge bot commented Sep 21, 2021

Webrevs

@pavelrappo
Copy link
Member

@pavelrappo pavelrappo commented Sep 21, 2021

This will need to be thoroughly tested to make sure there were no implicit dependencies on now-removed happens-before edges (initCause is synchronized). That said, the idea behind this clean-up looks good.

Copy link
Contributor

@wangweij wangweij left a comment

Looks fine. Thanks.

@openjdk
Copy link

@openjdk openjdk bot commented Sep 21, 2021

@turbanoff 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:

8274079: Cleanup unnecessary calls to Throwable.initCause() in java.base module

Reviewed-by: weijun

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

  • 3953e07: 8271459: C2: Missing NegativeArraySizeException when creating StringBuilder with negative capacity
  • 53d7e95: 8274635: Use String.equals instead of String.compareTo in jdk.accessibility
  • e43f540: 8274651: Possible race in FontDesignMetrics.KeyReference.dispose
  • 2e542e3: 8274349: ForkJoinPool.commonPool() does not work with 1 CPU
  • 7e757f6: 8274559: JFR: Typo in 'jfr help configure' text
  • 75d6688: 8274745: ProblemList TestSnippetTag.java
  • 9914e5c: 8274610: Add linux-aarch64 to bootcycle build profiles
  • 0ca094b: 8273244: Improve diagnostic output related to ErroneousTree
  • 6f727d8: 8274666: rename HtmlStyle.descfrmTypeLabel to be less cryptic
  • 139a833: 8268869: java in source-file mode suggests javac-only Xlint flags
  • ... and 207 more: https://git.openjdk.java.net/jdk/compare/7e92abe7a4bd2840fed19826fbff0285732f1765...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 (@wangweij) 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 the ready label Sep 21, 2021
@turbanoff
Copy link
Member Author

@turbanoff turbanoff commented Oct 5, 2021

/integrate

@openjdk openjdk bot added the sponsor label Oct 5, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Oct 5, 2021

@turbanoff
Your change (at version 9e0e045) is now ready to be sponsored by a Committer.

@wangweij
Copy link
Contributor

@wangweij wangweij commented Oct 5, 2021

/sponsor

@openjdk
Copy link

@openjdk openjdk bot commented Oct 5, 2021

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

  • 8609ea5: 8273342: Null pointer dereference in classFileParser.cpp:2817
  • a5080ef: 8272564: Incorrect attribution of method invocations of Object methods on interfaces
  • a914ee7: 8274632: Possible pointer overflow in PretouchTask chunk claiming
  • 8f7a37c: 8274434: move os::get_default_process_handle and os::dll_lookup to os_posix for POSIX platforms
  • 3953e07: 8271459: C2: Missing NegativeArraySizeException when creating StringBuilder with negative capacity
  • 53d7e95: 8274635: Use String.equals instead of String.compareTo in jdk.accessibility
  • e43f540: 8274651: Possible race in FontDesignMetrics.KeyReference.dispose
  • 2e542e3: 8274349: ForkJoinPool.commonPool() does not work with 1 CPU
  • 7e757f6: 8274559: JFR: Typo in 'jfr help configure' text
  • 75d6688: 8274745: ProblemList TestSnippetTag.java
  • ... and 211 more: https://git.openjdk.java.net/jdk/compare/7e92abe7a4bd2840fed19826fbff0285732f1765...master

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot closed this Oct 5, 2021
@openjdk openjdk bot added integrated and removed ready rfr sponsor labels Oct 5, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Oct 5, 2021

@wangweij @turbanoff Pushed as commit 1459180.

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

@turbanoff turbanoff deleted the unnecessary_call_to_Throwable.initCause_in_java.base branch Feb 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core-libs integrated net security
3 participants