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

Async IO for GZIPEncodingInterceptor

    XMLWordPrintable

Details

    Description

      GZIPEncodingInterceptor can't be used in the embedded Netty server, because it doesn't implement AsyncWriterInterceptor.

      If used, the following exception is thrown:

      java.lang.RuntimeException: Cannot use blocking IO with interceptors when we're on the IO thread
          at org.jboss.resteasy.plugins.server.netty.NettyHttpRequest$NettyExecutionContext.executeBlockingIo(NettyHttpRequest.java:279)
          at org.jboss.resteasy.core.interception.jaxrs.ServerWriterInterceptorContext.writeTo(ServerWriterInterceptorContext.java:79)
          at org.jboss.resteasy.core.interception.jaxrs.AbstractWriterInterceptorContext.syncProceed(AbstractWriterInterceptorContext.java:245)
          at org.jboss.resteasy.core.interception.jaxrs.AbstractWriterInterceptorContext.proceed(AbstractWriterInterceptorContext.java:224)
          at org.jboss.resteasy.plugins.interceptors.GZIPEncodingInterceptor.aroundWriteTo(GZIPEncodingInterceptor.java:92)
          ...
      

       

      Full stacktrace attached.

      Attachments

        Activity

          People

            Unassigned Unassigned
            txema-martinez-scopely Txema Martinez (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: