Interface HttpMessageExecutionContext
- All Superinterfaces:
BaseExecutionContext,BaseMessageExecutionContext,HttpBaseExecutionContext
- All Known Subinterfaces:
ExecutionContext,HttpExecutionContext,MessageExecutionContext
public interface HttpMessageExecutionContext
extends HttpBaseExecutionContext, BaseMessageExecutionContext
Specialize http execution context allowing access to an
HttpMessageRequest and HttpMessageResponse that manipulates flow of messages.- 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.Flowable<Message>interruptMessagesWith(ExecutionFailure failure) Same asBaseMessageExecutionContext.interruptMessages()but with anExecutionFailureobject that indicates that the execution has failed.io.reactivex.rxjava3.core.Maybe<Message>interruptMessageWith(ExecutionFailure failure) Same asBaseMessageExecutionContext#interruptMessagesWith(ExecutionFailure)but at message levelrequest()Get the current request attached to this execution context.response()Get the current response attached 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.base.BaseMessageExecutionContext
getTemplateEngine, interruptMessage, interruptMessagesMethods inherited from interface io.gravitee.gateway.reactive.api.context.http.HttpBaseExecutionContext
metrics
-
Field Details
-
TEMPLATE_ATTRIBUTE_MESSAGE
- See Also:
-
-
Method Details
-
request
HttpMessageRequest request()Get the current request attached to this execution context.- Specified by:
requestin interfaceHttpBaseExecutionContext- Returns:
- the request attached to this execution context.
-
response
HttpMessageResponse response()Get the current response attached to this execution context.- Specified by:
responsein interfaceHttpBaseExecutionContext- Returns:
- the response attached to this execution context.
-
interruptMessagesWith
Same asBaseMessageExecutionContext.interruptMessages()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, ...). -
interruptMessageWith
Same asBaseMessageExecutionContext#interruptMessagesWith(ExecutionFailure)but at message level
-