Package io.micronaut.http.client.filters
Class ClientServerContextFilter
java.lang.Object
io.micronaut.http.client.filters.ClientServerContextFilter
- All Implemented Interfaces:
Ordered
,HttpClientFilter
,HttpFilter
A client filter that propagates the request context.
- Since:
- 1.0
- Author:
- graemerocher
-
Field Summary
Fields inherited from interface io.micronaut.core.order.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
-
Constructor Summary
ConstructorDescriptionClientServerContextFilter
(HttpRequest<?> parentRequest) Default constructor. -
Method Summary
Modifier and TypeMethodDescriptionPublisher<? extends HttpResponse<?>>
doFilter
(MutableHttpRequest<?> request, ClientFilterChain chain) A variation ofHttpFilter.doFilter(HttpRequest, FilterChain)
that receives aMutableHttpRequest
allowing the request to be modified.int
getOrder()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.micronaut.http.filter.HttpClientFilter
doFilter
-
Constructor Details
-
ClientServerContextFilter
Default constructor.- Parameters:
parentRequest
- The parent request
-
-
Method Details
-
getOrder
public int getOrder() -
doFilter
public Publisher<? extends HttpResponse<?>> doFilter(MutableHttpRequest<?> request, ClientFilterChain chain) Description copied from interface:HttpClientFilter
A variation ofHttpFilter.doFilter(HttpRequest, FilterChain)
that receives aMutableHttpRequest
allowing the request to be modified.- Specified by:
doFilter
in interfaceHttpClientFilter
- Parameters:
request
- The requestchain
- The filter chain- Returns:
- The publisher of the response
- See Also:
-