Interface HttpPlainExecutionContext
- All Superinterfaces:
BaseExecutionContext,HttpBaseExecutionContext
- All Known Subinterfaces:
ExecutionContext,HttpExecutionContext,HttpExecutionContext
Http execution context allowing access to
HttpPlainRequest and HttpPlainResponse that manipulates raw http bodies (content or chunks).- Author:
- Jeoffrey HAEYAERT (jeoffrey.haeyaert at graviteesource.com), GraviteeSource Team
-
Field Summary
FieldsFields inherited from interface io.gravitee.gateway.reactive.api.context.base.BaseExecutionContext
TEMPLATE_ATTRIBUTE_CONTEXT -
Method Summary
Modifier and TypeMethodDescriptionio.reactivex.rxjava3.core.CompletableInterrupts the current execution while indicating that the response can be sent "as is" to the downstream.io.reactivex.rxjava3.core.Maybe<Buffer>Interrupts the current execution while indicating that the response can be sent "as is" to the downstream.io.reactivex.rxjava3.core.Maybe<Buffer>interruptBodyWith(ExecutionFailure failure) Same asinterruptBody()but with anExecutionFailureobject that indicates that the execution has failed.io.reactivex.rxjava3.core.CompletableinterruptWith(ExecutionFailure failure) Same asinterrupt()but with anExecutionFailureobject that indicates that the execution has failed.request()Get the current request stuck to this execution context.response()Get the current response stuck to this execution context.Methods inherited from interface io.gravitee.gateway.reactive.api.context.base.BaseExecutionContext
getAttribute, getAttributeAsList, getAttributeNames, getAttributes, getComponent, getInternalAttribute, getInternalAttributes, getTemplateEngine, getTracer, localAddress, putAttribute, putInternalAttribute, remoteAddress, removeAttribute, removeInternalAttribute, setAttribute, setInternalAttribute, timestamp, tlsSession, warnWithMethods inherited from interface io.gravitee.gateway.reactive.api.context.http.HttpBaseExecutionContext
metrics
-
Field Details
-
TEMPLATE_ATTRIBUTE_REQUEST
- See Also:
-
TEMPLATE_ATTRIBUTE_RESPONSE
- See Also:
-
-
Method Details
-
request
HttpPlainRequest request()Get the current request stuck to this execution context.- Specified by:
requestin interfaceHttpBaseExecutionContext- Returns:
- the request attached to this execution context.
-
response
HttpPlainResponse response()Get the current response stuck to this execution context.- Specified by:
responsein interfaceHttpBaseExecutionContext- Returns:
- the response attached to this execution context.
-
interrupt
io.reactivex.rxjava3.core.Completable interrupt()Interrupts the current execution while indicating that the response can be sent "as is" to the downstream. This has direct impact on how the remaining execution flow will behave (ex: remaining policies in a policy chain won't be executed). -
interruptWith
Same asinterrupt()but with anExecutionFailureobject that indicates that the execution has failed. TheExecutionFailurecan be processed in order to build a proper response (ex: based on templating, with appropriate accept-encoding, ...). -
interruptBody
io.reactivex.rxjava3.core.Maybe<Buffer> interruptBody()Interrupts the current execution while indicating that the response can be sent "as is" to the downstream. This has direct impact on how the remaining execution flow will behave (ex: remaining policies in a policy chain won't be executed). -
interruptBodyWith
Same asinterruptBody()but with anExecutionFailureobject that indicates that the execution has failed. TheExecutionFailurecan be processed in order to build a proper response (ex: based on templating, with appropriate accept-encoding, ...).
-