@Singleton @Internal public class HttpClientIntroductionAdvice extends Object implements MethodInterceptor<Object,Object>, Closeable, AutoCloseable
Client
annotation.HOTSWAP, LAZY, PROXY_TARGET
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
Constructor and Description |
---|
HttpClientIntroductionAdvice(BeanContext beanContext,
JsonMediaTypeCodec jsonMediaTypeCodec,
LoadBalancerResolver loadBalancerResolver,
List<ReactiveClientResultTransformer> transformers)
Constructor for advice class to setup things like Headers, Cookies, Parameters for Clients.
|
HttpClientIntroductionAdvice(BeanContext beanContext,
JsonMediaTypeCodec jsonMediaTypeCodec,
LoadBalancerResolver loadBalancerResolver,
ReactiveClientResultTransformer... transformers)
Constructor for advice class to setup things like Headers, Cookies, Parameters for Clients.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Cleanup method to prevent resource leaking.
|
Object |
intercept(MethodInvocationContext<Object,Object> context)
Interceptor to apply headers, cookies, parameter and body arguements.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
intercept
public HttpClientIntroductionAdvice(BeanContext beanContext, JsonMediaTypeCodec jsonMediaTypeCodec, LoadBalancerResolver loadBalancerResolver, ReactiveClientResultTransformer... transformers)
beanContext
- context to resolve beansjsonMediaTypeCodec
- The JSON media type codecloadBalancerResolver
- load balancer resolvertransformers
- transformation classes@Inject public HttpClientIntroductionAdvice(BeanContext beanContext, JsonMediaTypeCodec jsonMediaTypeCodec, LoadBalancerResolver loadBalancerResolver, List<ReactiveClientResultTransformer> transformers)
beanContext
- context to resolve beansjsonMediaTypeCodec
- The JSON media type codecloadBalancerResolver
- load balancer resolvertransformers
- transformation classespublic Object intercept(MethodInvocationContext<Object,Object> context)
intercept
in interface MethodInterceptor<Object,Object>
context
- The context@PreDestroy public void close()
close
in interface Closeable
close
in interface AutoCloseable