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

Need to set the http protocol version in HttpURLConnection

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Won't Fix
    • Icon: P5 P5
    • None
    • 6
    • core-libs
    • x86
    • windows_xp

      A DESCRIPTION OF THE REQUEST :
      We need the capability to set http protocol version in HttpURLConnection. The current implementation does not have the capability.

      JUSTIFICATION :
      Building the middle application that sends http request and gets http response for some other http clients which only support http 1.0. The current implementation of HttpURLConnection assumes http 1.1 which will cause the server to response with those headers that 1.0 http clients do not understand (i.e Transfer-Encoding: chunked which does not follow RFC spec: server should not send Transfer-Encoding: chunked to http 1.0 clients)

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      HttpURLConnection.setProtocolVersion()

      CUSTOMER SUBMITTED WORKAROUND :
      Use apache HttpClient

            chegar Chris Hegarty
            ndcosta Nelson Dcosta (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: