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

URIBuilder optimization prevents relative paths that startWith "h" "t" "t" "p"

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.5.10, 2.6.8, 2.7.5
    • 2.5.11, 2.6.9, 2.7.6, 3.0.0-milestone1
    • None
    • None
    • Unknown

    Description

      URI uri = new URI("http://foo/bar/baz;m1=m1value");
      URI newUri = new UriBuilderImpl(uri).replacePath("httppnewpath").build();
      assertEquals("URI is not built correctly", "http://foo/httppnewpath", newUri.toString());

      Should pass, but results in:

      FAILURE!
      org.junit.ComparisonFailure: URI is not built correctly expected:<http://foo/httppnewpath> but was:<http:[]httppnewpath>
      at org.junit.Assert.assertEquals(Assert.java:115)
      at org.apache.cxf.jaxrs.impl.UriBuilderImplTest.testReplacePathHttpString(UriBuilderImplTest.java:537)

      Attachments

        1. CXF-5084.patch
          2 kB
          David Blevins

        Issue Links

          Activity

            People

              sergey_beryozkin Sergey Beryozkin
              dblevins David Blevins
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: