Class QuarkusResteasyReactiveRequestContext

java.lang.Object
org.jboss.resteasy.reactive.common.core.AbstractResteasyReactiveContext<org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext,org.jboss.resteasy.reactive.server.spi.ServerRestHandler>
org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext
org.jboss.resteasy.reactive.server.vertx.VertxResteasyReactiveRequestContext
io.quarkus.resteasy.reactive.server.runtime.QuarkusResteasyReactiveRequestContext
All Implemented Interfaces:
io.vertx.core.Handler<Void>, Closeable, AutoCloseable, Runnable, org.jboss.resteasy.reactive.common.core.ResteasyReactiveCallbackContext, org.jboss.resteasy.reactive.server.injection.ResteasyReactiveInjectionContext, org.jboss.resteasy.reactive.server.spi.ServerHttpRequest, org.jboss.resteasy.reactive.server.spi.ServerHttpResponse, org.jboss.resteasy.reactive.server.spi.ServerRequestContext, org.jboss.resteasy.reactive.server.spi.StreamingResponse<org.jboss.resteasy.reactive.server.spi.ServerHttpResponse>

public class QuarkusResteasyReactiveRequestContext extends VertxResteasyReactiveRequestContext
  • Field Details

    • association

      final io.quarkus.security.identity.CurrentIdentityAssociation association
    • userSetup

      boolean userSetup
  • Constructor Details

    • QuarkusResteasyReactiveRequestContext

      public QuarkusResteasyReactiveRequestContext(org.jboss.resteasy.reactive.server.core.Deployment deployment, io.vertx.ext.web.RoutingContext context, org.jboss.resteasy.reactive.spi.ThreadSetupAction requestContext, org.jboss.resteasy.reactive.server.spi.ServerRestHandler[] handlerChain, org.jboss.resteasy.reactive.server.spi.ServerRestHandler[] abortHandlerChain, ClassLoader devModeTccl, io.quarkus.security.identity.CurrentIdentityAssociation currentIdentityAssociation)
  • Method Details

    • handleRequestScopeActivation

      protected void handleRequestScopeActivation()
      Overrides:
      handleRequestScopeActivation in class org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext
    • requestScopeDeactivated

      protected void requestScopeDeactivated()
      Overrides:
      requestScopeDeactivated in class org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext
    • createSecurityContext

      protected jakarta.ws.rs.core.SecurityContext createSecurityContext()
      Overrides:
      createSecurityContext in class org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext
    • handleUnrecoverableError

      protected void handleUnrecoverableError(Throwable throwable)
      Overrides:
      handleUnrecoverableError in class org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext
    • handlesUnmappedException

      public boolean handlesUnmappedException()
      Overrides:
      handlesUnmappedException in class org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext
    • handleUnmappedException

      public void handleUnmappedException(Throwable throwable)
      Overrides:
      handleUnmappedException in class org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext
    • invokeHandler

      protected void invokeHandler(int pos) throws Exception
      The implementation looks like it makes no sense, but it in fact does make sense from a performance perspective. The idea is to reduce the use instances of megamorphic calls into a series of instance checks and monomorphic calls. The rationale behind this is fully explored in https://shipilev.net/blog/2015/black-magic-method-dispatch/#_cheating_the_runtime_2 and this specific instance has been verified experimentally to result in better performance.
      Overrides:
      invokeHandler in class org.jboss.resteasy.reactive.common.core.AbstractResteasyReactiveContext<org.jboss.resteasy.reactive.server.core.ResteasyReactiveRequestContext,org.jboss.resteasy.reactive.server.spi.ServerRestHandler>
      Throws:
      Exception