Open
Description
Add context propagation support via Micrometer Context Propagation for the SecurityContext
, between SecurityContextHolder
and ReactiveSecurityContextHolder
.
This would allow applications to easily cross between the reactive <-> imperative border in either direction, and have the SecurityContext
available on both sides.
Examples:
- a WebFlux application could use the
handle
ortap
operators (which propagate from Context to ThreadLocals) to call into imperative code that expects theSecurityContext
to be accessible fromSecurityContextHolder
. - a Spring WebMVC application could use the
captureContext
operator (which propagates ThreadLocals to Context) to call into reactive code that expects theSecurityContext
to be accessible fromReactiveSecurityContextHolder
.