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

BuiltResponse.close() should also call ResteasyProviderFactory.clearInstanceIfEqual

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • None
    • 4.4.0.Final
    • jaxrs
    • None

      ClientFilterResponseBuilderTest causes tests AllowGzipOnServerAllowGzipOnClientTest
      and NotAllowGzipOnServerAllowGzipOnClientTest to fail. The cause is the test
      is creating an instance of ResteasyProviderFactory that is not (closed) cleaned-up
      after use. This instance lives on into the following tests which causes them to fail.
      The failure is unique to ClientFilterResponseBuilderTest because this test
      registers a ClientResponseFilter implementation (class ResponseBuilderCustomResponseFilter)
      which creates a new response object. The call to response.readEntity() causes
      a new ResteasyProviderFactory to be created so a message reader can be found.
      Method readEntity calls BuiltResponse.close() but it only sets a flag currently.
      It does not check the ResteasyProviderFactory, "instance" value.

              rsearls r searls
              rsearls r searls
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: