Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8330572

jdk.internal.net.http.HttpConnection calls an expensive checkOpen() when returning a HTTP/1.1 connection to the pool

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 23
    • 17
    • core-libs
    • b20

      jdk.internal.net.http.HttpConnection has an internal checkOpen() method which does a socket channel read. This method is expected to be called only when a non-TLS HTTP/1.1 connection is being picked out from the connection pool and before handing it out to use. The checkOpen() method as the javadoc states is an expensive method, given that its does a channel read operation.

      Right now this method is even being called when a HTTP connection is being returned back to the pool. This is unnecessary and should be avoided.

            jpai Jaikiran Pai
            jpai Jaikiran Pai
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: