Uploaded image for project: 'RESTEasy'
  1. RESTEasy
  2. RESTEASY-2329

Remove unnecessary array copy and resizing for headers

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Done
    • Icon: Major Major
    • 4.3.0.Final
    • None
    • None
    • None

      JFR shows that for each header, an empty `ArrayList` is created and then a new element is added to it. This causes the code to go through `grow` unnecessarily. In addition, most of the time, it just needs 1 element for the array, while `ArrayList` creates a size 10 array by default.

      It is a minor thing, but just wanted to address. Please see PR https://github.com/resteasy/Resteasy/pull/2141.

            rhn-support-asoldano Alessio Soldano
            gurselan Anil Gursel (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: