@Filter(value="/**") public class HttpSessionFilter extends Object implements HttpServerFilter
HttpServerFilter that resolves the current user Session if present and encodes the Session ID in
the response.| Modifier and Type | Field and Description |
|---|---|
static Integer |
ORDER
The order of the filter.
|
static CharSequence |
SESSION_ATTRIBUTE
Constant for Micronaut SESSION attribute.
|
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE| Constructor and Description |
|---|
HttpSessionFilter(SessionStore<Session> sessionStore,
HttpSessionIdResolver[] resolvers,
HttpSessionIdEncoder[] encoders)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Publisher<MutableHttpResponse<?>> |
doFilter(HttpRequest<?> request,
ServerFilterChain chain)
Variation of the
HttpServerFilter.doFilter(HttpRequest, FilterChain) method that accepts a ServerFilterChain
which allows to mutate the outgoing HTTP response. |
int |
getOrder() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdoFilterpublic static final Integer ORDER
public static final CharSequence SESSION_ATTRIBUTE
public HttpSessionFilter(SessionStore<Session> sessionStore, HttpSessionIdResolver[] resolvers, HttpSessionIdEncoder[] encoders)
sessionStore - The session storeresolvers - The HTTP session id resolversencoders - The HTTP session id encoderspublic int getOrder()
public Publisher<MutableHttpResponse<?>> doFilter(HttpRequest<?> request, ServerFilterChain chain)
HttpServerFilterHttpServerFilter.doFilter(HttpRequest, FilterChain) method that accepts a ServerFilterChain
which allows to mutate the outgoing HTTP response.doFilter in interface HttpServerFilterrequest - The requestchain - The chainPublisher that emits a MutableHttpResponseHttpServerFilter.doFilter(HttpRequest, FilterChain)