Class CustomInterceptor

  • All Implemented Interfaces:
    jakarta.ws.rs.ext.WriterInterceptor

    @ApplicationScoped
    public class CustomInterceptor
    extends Object
    implements jakarta.ws.rs.ext.WriterInterceptor
    CDI based JAX-RS interceptor that re-writes the original output with request ID obtained from another CDI bean.
    Author:
    Jakub Podlesak
    • Constructor Detail

      • CustomInterceptor

        public CustomInterceptor()
    • Method Detail

      • aroundWriteTo

        public void aroundWriteTo​(jakarta.ws.rs.ext.WriterInterceptorContext context)
                           throws IOException,
                                  jakarta.ws.rs.WebApplicationException
        Specified by:
        aroundWriteTo in interface jakarta.ws.rs.ext.WriterInterceptor
        Throws:
        IOException
        jakarta.ws.rs.WebApplicationException