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

8303216: Prefer ArrayList to LinkedList in sun.net.httpserver.ServerImpl #12756

Conversation

turbanoff
Copy link
Member

@turbanoff turbanoff commented Feb 26, 2023

LinkedList is used in a few places in ServerImpl.
There is only add/iterator/clear/size calls on this lists. No removes from the head or something like this. ArrayList should be preferred as more efficient and widely used (more chances for JIT) collection.


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

  • JDK-8303216: Prefer ArrayList to LinkedList in sun.net.httpserver.ServerImpl

Reviewers

Reviewing

Using git

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

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

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 12756

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

Using diff file

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

@bridgekeeper
Copy link

bridgekeeper bot commented Feb 26, 2023

👋 Welcome back aturbanov! 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.

@turbanoff turbanoff changed the title [PATCH] Prefer ArrayList to LinkedList in sun.net.httpserver.ServerImpl 8303216: Prefer ArrayList to LinkedList in sun.net.httpserver.ServerImpl Feb 26, 2023
@openjdk
Copy link

openjdk bot commented Feb 26, 2023

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

  • net

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 net net-dev@openjdk.org rfr Pull request is ready for review labels Feb 26, 2023
@mlbridge
Copy link

mlbridge bot commented Feb 26, 2023

Webrevs

Copy link
Member

@jaikiran jaikiran left a comment

Choose a reason for hiding this comment

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

Looks fine to me.

@openjdk
Copy link

openjdk bot commented Feb 27, 2023

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

8303216: Prefer ArrayList to LinkedList in sun.net.httpserver.ServerImpl

Reviewed-by: jpai, vtewari, stsypanov, dfuchs

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

  • 30302d1: 8303250: Call ct_max_alignment_constraint using the base class
  • e144783: 8299817: [s390] AES-CTR mode intrinsic fails with multiple short update() calls
  • 5feb13b: 8301701: java/net/DatagramSocket/DatagramSocketMulticasting.java should be hardened
  • 1e3c9fd: 8026369: javac potentially ambiguous overload warning needs an improved scheme
  • 14a014d: 8302124: HotSpot Style Guide should permit noreturn attribute
  • bca60f4: 8303249: JFR: Incorrect description of dumponexit
  • f7f1036: 8303068: Memory leak in DwarfFile::LineNumberProgram::run_line_number_program
  • 784f7b1: 8293667: Align jlink's --compress option with jmod's --compress option
  • 54603aa: 8303208: JFR: 'jfr print' displays incorrect timestamps
  • 4c169d2: 8303253: Remove unnecessary calls to super() in java.time value based classes
  • ... and 16 more: https://git.openjdk.org/jdk/compare/2fb1e3b7e72cf7836a9ffd9c6a5b09a6eef3c01b...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 27, 2023
Copy link
Contributor

@vyommani vyommani left a comment

Choose a reason for hiding this comment

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

Looks OK to me.

@turbanoff
Copy link
Member Author

/integrate

@openjdk
Copy link

openjdk bot commented Feb 28, 2023

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

Your commit was automatically rebased without conflicts.

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

openjdk bot commented Feb 28, 2023

@turbanoff Pushed as commit 8815175.

💡 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 net net-dev@openjdk.org
Development

Successfully merging this pull request may close these issues.

5 participants