Class EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher
java.lang.Object
org.springframework.boot.security.reactive.ApplicationContextServerWebExchangeMatcher<PathMappedEndpoints>
org.springframework.boot.security.autoconfigure.actuate.reactive.EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher
- All Implemented Interfaces:
ServerWebExchangeMatcher
- Enclosing class:
EndpointRequest
public static class EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher
extends ApplicationContextServerWebExchangeMatcher<PathMappedEndpoints>
The
ServerWebExchangeMatcher
used to match against additional paths for
actuator endpoints
.- Since:
- 4.0.0
- Author:
- Madhura Bhave, Phillip Webb, Chris Bono
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher
ServerWebExchangeMatcher.MatchResult
-
Method Summary
Modifier and TypeMethodDescriptionprotected ServerWebExchangeMatcher
createDelegate
(PathMappedEndpoints endpoints) protected final List
<ServerWebExchangeMatcher> getDelegateMatchers
(Set<String> paths, @Nullable HttpMethod httpMethod) protected final EndpointId
getEndpointId
(Object source) protected final boolean
hasWebServerNamespace
(@Nullable ApplicationContext applicationContext, WebServerNamespace webServerNamespace) protected boolean
ignoreApplicationContext
(@Nullable ApplicationContext applicationContext) Returns if theApplicationContext
should be ignored and not used for matching.protected boolean
ignoreApplicationContext
(@Nullable ApplicationContext applicationContext, ManagementPortType managementPortType) protected void
initialized
(Supplier<PathMappedEndpoints> supplier) Called once the context has been initialized.protected reactor.core.publisher.Mono
<ServerWebExchangeMatcher.MatchResult> matches
(ServerWebExchange exchange, Supplier<PathMappedEndpoints> context) Decides whether the rule implemented by the strategy matches the supplied exchange.toString()
protected final String
withHttpMethod
(HttpMethod httpMethod) Restricts the matcher to only consider requests with a particular HTTP method.Methods inherited from class org.springframework.boot.security.reactive.ApplicationContextServerWebExchangeMatcher
getContext, matches
-
Method Details
-
withHttpMethod
public EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher withHttpMethod(HttpMethod httpMethod) Restricts the matcher to only consider requests with a particular HTTP method.- Parameters:
httpMethod
- the HTTP method to include- Returns:
- a copy of the matcher further restricted to only match requests with the specified HTTP method
-
ignoreApplicationContext
protected boolean ignoreApplicationContext(@Nullable ApplicationContext applicationContext, ManagementPortType managementPortType) -
createDelegate
-
toString
-
initialized
Description copied from class:ApplicationContextServerWebExchangeMatcher
Called once the context has been initialized.- Overrides:
initialized
in classApplicationContextServerWebExchangeMatcher<C>
- Parameters:
supplier
- a supplier for the initialized context (may throw an exception)
-
getDelegateMatchers
protected final List<ServerWebExchangeMatcher> getDelegateMatchers(Set<String> paths, @Nullable HttpMethod httpMethod) -
matches
protected reactor.core.publisher.Mono<ServerWebExchangeMatcher.MatchResult> matches(ServerWebExchange exchange, Supplier<PathMappedEndpoints> context) Description copied from class:ApplicationContextServerWebExchangeMatcher
Decides whether the rule implemented by the strategy matches the supplied exchange.- Specified by:
matches
in classApplicationContextServerWebExchangeMatcher<C>
- Parameters:
exchange
- the source exchangecontext
- a supplier for the initialized context (may throw an exception)- Returns:
- if the exchange matches
-
ignoreApplicationContext
Description copied from class:ApplicationContextServerWebExchangeMatcher
Returns if theApplicationContext
should be ignored and not used for matching. If this method returnstrue
then the context will not be used and thematches
method will returnfalse
.- Overrides:
ignoreApplicationContext
in classApplicationContextServerWebExchangeMatcher<C>
- Parameters:
applicationContext
- the candidate application context- Returns:
- if the application context should be ignored
-
hasWebServerNamespace
protected final boolean hasWebServerNamespace(@Nullable ApplicationContext applicationContext, WebServerNamespace webServerNamespace) -
toString
-
getEndpointId
-