jersey
  1. jersey
  2. JERSEY-1398

AsyncInvoker.delete(GenericType<Response> responseType) throws Exception

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Duplicate
    • Affects Version/s: 2.0-m06
    • Fix Version/s: 2.0-m08, 2.0
    • Component/s: core
    • Labels:
      None

      Description

      javadoc says:

      Note that calling the Future.get() method on the returned Future instance may throw an ExecutionException that wraps a WebApplicationException or one of its subclasses thrown in case the received response status code is not successful and the specified response type is not Response.

      This evokes that

      		Future<Response> future = AsyncInvoker.delete(new GenericType(Response.class));
      

      is valid. However, the following exception is thrown:

      ERROR: java.util.concurrent.ExecutionException: javax.ws.rs.client.ClientException: Unexpected error during response processing.
      at com.google.common.util.concurrent.AbstractFuture$Sync.getValue(AbstractFuture.java:294)
      at com.google.common.util.concurrent.AbstractFuture$Sync.get(AbstractFuture.java:281)
      at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:116)
      at com.sun.ts.tests.jaxrs.ee.rs.client.asyncinvoker.JAXRSClient.checkFutureOkResponseNoTime(JAXRSClient.java:912)
      at com.sun.ts.tests.jaxrs.ee.rs.client.asyncinvoker.JAXRSClient.checkFutureOkResponse(JAXRSClient.java:922)
      at com.sun.ts.tests.jaxrs.ee.rs.client.asyncinvoker.JAXRSClient.deleteWithGenericTypeResponseWhileServerWaitTest(JAXRSClient.j

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at com.sun.ts.lib.harness.EETest.run(EETest.java:495)
      at com.sun.ts.lib.harness.ServiceEETest.run(ServiceEETest.java:113)
      at com.sun.ts.tests.common.vehicle.EmptyVehicleRunner.run(EmptyVehicleRunner.java:30)
      at com.sun.ts.lib.harness.ServiceEETest.run(ServiceEETest.java:102)
      at com.sun.ts.lib.harness.EETest.getPropsReady(EETest.java:392)
      at com.sun.ts.lib.harness.ServiceEETest.run(ServiceEETest.java:210)
      at com.sun.ts.lib.harness.EETest.run(EETest.java:204)
      at com.sun.ts.tests.common.vehicle.VehicleClient.main(VehicleClient.java:27)
      Caused by: javax.ws.rs.client.ClientException: Unexpected error during response processing.
      at org.glassfish.jersey.client.JerseyInvocation$3.completed(JerseyInvocation.java:633)
      at org.glassfish.jersey.client.ClientConfig$State$5$1.result(ClientConfig.java:462)
      at org.glassfish.jersey.client.ClientConfig$State$5$1.result(ClientConfig.java:458)
      at org.glassfish.jersey.process.internal.ResponseProcessor.notifyCallback(ResponseProcessor.java:314)
      at org.glassfish.jersey.process.internal.ResponseProcessor.setResult(ResponseProcessor.java:300)
      at org.glassfish.jersey.process.internal.ResponseProcessor.access$600(ResponseProcessor.java:82)
      at org.glassfish.jersey.process.internal.ResponseProcessor$1.run(ResponseProcessor.java:242)
      at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:303)
      at org.glassfish.jersey.process.internal.ResponseProcessor.run(ResponseProcessor.java:187)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:662)
      Caused by: org.glassfish.jersey.message.internal.MessageBodyProviderNotFoundException: MessageBodyReader not found for media type=tex
      ss javax.ws.rs.core.Response, genericType=class javax.ws.rs.core.Response.
      at org.glassfish.jersey.message.internal.ReaderInterceptorExecutor$TerminalReaderInterceptor.aroundReadFrom(ReaderInterceptorE
      )
      at org.glassfish.jersey.message.internal.ReaderInterceptorExecutor.proceed(ReaderInterceptorExecutor.java:158)
      at org.glassfish.jersey.message.internal.ExceptionWrapperInterceptor.aroundReadFrom(ExceptionWrapperInterceptor.java:70)
      at org.glassfish.jersey.message.internal.ReaderInterceptorExecutor.proceed(ReaderInterceptorExecutor.java:158)
      at org.glassfish.jersey.message.internal.MessageBodyFactory.readFrom(MessageBodyFactory.java:612)
      at org.glassfish.jersey.message.internal.InboundMessageContext.readEntity(InboundMessageContext.java:902)
      at org.glassfish.jersey.message.internal.InboundMessageContext.readEntity(InboundMessageContext.java:878)
      at org.glassfish.jersey.client.InboundJaxrsResponse.readEntity(InboundJaxrsResponse.java:100)
      at org.glassfish.jersey.client.JerseyInvocation$3.completed(JerseyInvocation.java:631)
      ... 11 more

        Issue Links

          Activity

          Hide
          Marek Potociar added a comment -

          Same issue

          Show
          Marek Potociar added a comment - Same issue

            People

            • Assignee:
              Marek Potociar
              Reporter:
              jan.supol
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 3 hours
                3h
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 5 minutes Time Not Required
                5m