Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-3518

WebClient doesn't handle responses containing a quoted-string in a header correctly

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.4, 2.3.4
    • Fix Version/s: 2.4.1, 2.3.5
    • Component/s: JAX-RS
    • Labels:
      None
    • Environment:

      JDK 1.6

    • Estimated Complexity:
      Novice

      Description

      Similar to CXF-2462, if a request returns a response header that looks like the following:

      q: "stuff with commas, and spaces"

      WebClient's response.getMetadata() returns 2 values:

      1. "stuff with commas
      2. and spaces"

      while the correct response should be:

      1. stuff with commas, and spaces

      Here's the WebClient code which reproduces the issue (as long as the server response contains a header that returns the header value above):

      Response r = WebClient.create(new URI("http://localhost:8080")).path("key/quoted").get();
      List<Object> l = r.getMetadata().get("q");
      

        Attachments

        1. trunk.wc_quote_minimal.diff
          3 kB
          Ka-Lok Fung
        2. trunk.webclient.quote.try2.diff
          10 kB
          Ka-Lok Fung

          Activity

            People

            • Assignee:
              sergey_beryozkin Sergey Beryozkin
              Reporter:
              kfung Ka-Lok Fung
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: