Class ConduitInjector

java.lang.Object
org.restheart.handlers.PipelinedHandler
org.restheart.handlers.injectors.ConduitInjector
All Implemented Interfaces:
io.undertow.server.HttpHandler

public class ConduitInjector extends PipelinedHandler
Executes the interceptors for proxied requests taking care of buffering the response from the backend to make it accessible to them whose requiresResponseContent() returns true Note that getting the content has significant performance overhead for proxied resources. To mitigate DoS attacks the injector limits the size of the content to ModificableContentSinkConduit.MAX_CONTENT_SIZE bytes
Author:
Andrea Di Cesare <andrea@softinstigate.com>
  • Field Details

    • MCSC_KEY

      public static final io.undertow.util.AttachmentKey<ModifiableContentSinkConduit> MCSC_KEY
    • ORIGINAL_ACCEPT_ENCODINGS_KEY

      public static final io.undertow.util.AttachmentKey<io.undertow.util.HeaderMap> ORIGINAL_ACCEPT_ENCODINGS_KEY
  • Constructor Details

    • ConduitInjector

      public ConduitInjector()
    • ConduitInjector

      public ConduitInjector(PipelinedHandler next)
      Parameters:
      next -
  • Method Details

    • handleRequest

      public void handleRequest(io.undertow.server.HttpServerExchange exchange) throws Exception
      Specified by:
      handleRequest in interface io.undertow.server.HttpHandler
      Specified by:
      handleRequest in class PipelinedHandler
      Parameters:
      exchange -
      Throws:
      Exception