Class RestClientRequestContext
java.lang.Object
org.jboss.resteasy.reactive.common.core.AbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
org.jboss.resteasy.reactive.client.impl.RestClientRequestContext
- All Implemented Interfaces:
Closeable,AutoCloseable,Runnable,ResteasyReactiveCallbackContext
public class RestClientRequestContext
extends AbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
This is a stateful invocation, you can't invoke it twice.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from class org.jboss.resteasy.reactive.common.core.AbstractResteasyReactiveContext
abortHandlerChain, CUSTOM_RR_PROPERTIES_PREFIX, handlers, log, logWebApplicationExceptions, position, throwable -
Constructor Summary
ConstructorsConstructorDescriptionRestClientRequestContext(ClientImpl restClient, io.vertx.core.http.HttpClient httpClient, String httpMethod, URI uri, ConfigurationImpl configuration, ClientRequestHeaders requestHeaders, jakarta.ws.rs.client.Entity<?> entity, jakarta.ws.rs.core.GenericType<?> responseType, boolean registerBodyHandler, Map<String, Object> properties, ClientRestHandler[] handlerChain, ClientRestHandler[] abortHandlerChain, ClientRestHandler[] abortHandlerChainWithoutResponseFilters, ThreadSetupAction requestContext) -
Method Summary
Modifier and TypeMethodDescriptionvoidabort()voidvoidclose()jakarta.ws.rs.core.Responseio.smallrye.stork.api.ServiceInstancejakarta.ws.rs.client.Entity<?>protected Executorio.vertx.core.http.HttpClientio.vertx.core.http.HttpClientRequestjakarta.ws.rs.ext.ReaderInterceptor[]List<io.netty.handler.codec.http.multipart.InterfaceHttpData>intjakarta.ws.rs.core.GenericType<?>getUri()io.vertx.core.http.HttpClientResponseprotected voidprotected voidhandleUnrecoverableError(Throwable throwable) voidinitialiseResponse(io.vertx.core.http.HttpClientResponse vertxResponse) booleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanprotected booleanboolean<T> TreadEntity(InputStream in, jakarta.ws.rs.core.GenericType<T> responseType, jakarta.ws.rs.core.MediaType mediaType, Annotation[] annotations, jakarta.ws.rs.core.MultivaluedMap<String, Object> metadata) protected voidrestarted(boolean keepTarget) setAbortedWith(jakarta.ws.rs.core.Response abortedWith) voidsetCallerStackTrace(StackTraceElement[] callerStackTrace) voidsetCallStatsCollector(io.smallrye.stork.api.ServiceInstance serviceInstance) setEntity(jakarta.ws.rs.client.Entity<?> entity) voidsetEntity(Object entity, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType) setHttpClientRequest(io.vertx.core.http.HttpClientRequest httpClientRequest) setHttpMethod(String httpMethod) voidsetMultipartResponsesData(Map<Class<?>, MultipartResponseData> multipartResponsesData) setResponseEntityStream(InputStream responseEntityStream) setResponseHeaders(jakarta.ws.rs.core.MultivaluedMap<String, String> responseHeaders) setResponseMultipartParts(List<io.netty.handler.codec.http.multipart.InterfaceHttpData> responseMultiParts) setResponseReasonPhrase(String responseReasonPhrase) setResponseStatus(int responseStatus) setResponseType(jakarta.ws.rs.core.GenericType<?> responseType) setResponseTypeSpecified(boolean responseTypeSpecified) voidsetTmpFilePath(String tmpFilePath) protected Throwableio.vertx.core.buffer.BufferwriteEntity(jakarta.ws.rs.client.Entity<?> entity, jakarta.ws.rs.core.MultivaluedMap<String, String> headerMap, jakarta.ws.rs.ext.WriterInterceptor[] interceptors) Methods inherited from class org.jboss.resteasy.reactive.common.core.AbstractResteasyReactiveContext
beginAsyncProcessing, captureCDIRequestScope, getAbortHandlerChain, getContextExecutor, getHandlers, getPosition, getProperty, getPropertyNames, getThrowable, handleException, handleException, invokeHandler, isSuspended, registerCompletionCallback, registerConnectionCallback, removeProperty, requestScopeDeactivated, requireCDIRequestScope, restart, restart, resume, resume, resume, resume, run, setAbortHandlerChain, setAbortHandlerChainStarted, setPosition, setProperty, setSuspended, suspend
-
Field Details
-
INVOKED_METHOD_PROP
- See Also:
-
INVOKED_METHOD_PARAMETERS_PROP
- See Also:
-
DEFAULT_CONTENT_TYPE_PROP
- See Also:
-
DEFAULT_USER_AGENT_VALUE
- See Also:
-
-
Constructor Details
-
RestClientRequestContext
public RestClientRequestContext(ClientImpl restClient, io.vertx.core.http.HttpClient httpClient, String httpMethod, URI uri, ConfigurationImpl configuration, ClientRequestHeaders requestHeaders, jakarta.ws.rs.client.Entity<?> entity, jakarta.ws.rs.core.GenericType<?> responseType, boolean registerBodyHandler, Map<String, Object> properties, ClientRestHandler[] handlerChain, ClientRestHandler[] abortHandlerChain, ClientRestHandler[] abortHandlerChainWithoutResponseFilters, ThreadSetupAction requestContext)
-
-
Method Details
-
abort
public void abort() -
getInvokedMethod
-
getMethodDeclaredAnnotationsSafe
-
unwrapException
- Overrides:
unwrapExceptionin classAbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
-
readEntity
public <T> T readEntity(InputStream in, jakarta.ws.rs.core.GenericType<T> responseType, jakarta.ws.rs.core.MediaType mediaType, Annotation[] annotations, jakarta.ws.rs.core.MultivaluedMap<String, Object> metadata) throws IOException- Throws:
IOException
-
getReaderInterceptors
public jakarta.ws.rs.ext.ReaderInterceptor[] getReaderInterceptors() -
getProperties
-
initialiseResponse
public void initialiseResponse(io.vertx.core.http.HttpClientResponse vertxResponse) -
getHttpClient
public io.vertx.core.http.HttpClient getHttpClient() -
getClientRequestContext
-
getOrCreateClientResponseContext
-
getOrCreateClientRequestContext
-
writeEntity
public io.vertx.core.buffer.Buffer writeEntity(jakarta.ws.rs.client.Entity<?> entity, jakarta.ws.rs.core.MultivaluedMap<String, String> headerMap, jakarta.ws.rs.ext.WriterInterceptor[] interceptors) throws IOException- Throws:
IOException
-
setEntity
public void setEntity(Object entity, Annotation[] annotations, jakarta.ws.rs.core.MediaType mediaType) -
getResult
-
getVertxClientResponse
public io.vertx.core.http.HttpClientResponse getVertxClientResponse() -
getEventLoop
- Specified by:
getEventLoopin classAbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
-
getHttpClientRequest
public io.vertx.core.http.HttpClientRequest getHttpClientRequest() -
setHttpClientRequest
public RestClientRequestContext setHttpClientRequest(io.vertx.core.http.HttpClientRequest httpClientRequest) -
handleRequestScopeActivation
protected void handleRequestScopeActivation()- Specified by:
handleRequestScopeActivationin classAbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
-
restarted
protected void restarted(boolean keepTarget) - Specified by:
restartedin classAbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classAbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
-
handleUnrecoverableError
- Specified by:
handleUnrecoverableErrorin classAbstractResteasyReactiveContext<RestClientRequestContext,ClientRestHandler>
-
getConfiguration
-
getRestClient
-
getResponseStatus
public int getResponseStatus() -
setResponseStatus
-
getResponseReasonPhrase
-
setResponseReasonPhrase
-
getResponseHeaders
-
setResponseHeaders
public RestClientRequestContext setResponseHeaders(jakarta.ws.rs.core.MultivaluedMap<String, String> responseHeaders) -
isCheckSuccessfulFamily
public boolean isCheckSuccessfulFamily() -
isResponseTypeSpecified
public boolean isResponseTypeSpecified() -
setResponseTypeSpecified
-
getResponseType
public jakarta.ws.rs.core.GenericType<?> getResponseType() -
setResponseType
-
getRequestHeaders
-
getHttpMethod
-
setHttpMethod
-
getUri
-
setUri
-
getEntity
public jakarta.ws.rs.client.Entity<?> getEntity() -
setEntity
-
isRegisterBodyHandler
public boolean isRegisterBodyHandler() -
getResponseEntityStream
-
setResponseEntityStream
-
setResponseMultipartParts
public RestClientRequestContext setResponseMultipartParts(List<io.netty.handler.codec.http.multipart.InterfaceHttpData> responseMultiParts) -
getResponseMultipartParts
-
isAborted
public boolean isAborted() -
getAbortedWith
public jakarta.ws.rs.core.Response getAbortedWith() -
setAbortedWith
-
isFileUpload
public boolean isFileUpload() -
isInputStreamUpload
public boolean isInputStreamUpload() -
isMultiBufferUpload
public boolean isMultiBufferUpload() -
isMultipart
public boolean isMultipart() -
isFileDownload
public boolean isFileDownload() -
isInputStreamDownload
public boolean isInputStreamDownload() -
getTmpFilePath
-
setTmpFilePath
-
clearTmpFilePath
public void clearTmpFilePath() -
getClientFilterProperties
-
getAbortHandlerChainWithoutResponseFilters
-
setCallStatsCollector
public void setCallStatsCollector(io.smallrye.stork.api.ServiceInstance serviceInstance) -
getCallStatsCollector
public io.smallrye.stork.api.ServiceInstance getCallStatsCollector() -
getMultipartResponsesData
-
setMultipartResponsesData
-
getCallerStackTrace
-
setCallerStackTrace
-
isRequestScopeManagementRequired
protected boolean isRequestScopeManagementRequired()
-