Class EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher
java.lang.Object
org.springframework.boot.security.web.reactive.ApplicationContextServerWebExchangeMatcher<org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints>
org.springframework.boot.security.autoconfigure.actuate.web.reactive.EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher
- All Implemented Interfaces:
org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher
- Enclosing class:
EndpointRequest
public static class EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher
extends ApplicationContextServerWebExchangeMatcher<org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints>
The
ServerWebExchangeMatcher used to match against additional paths for
actuator endpoints.- Since:
- 4.0.0
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher
org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher.MatchResult -
Method Summary
Modifier and TypeMethodDescriptionprotected org.springframework.security.web.server.util.matcher.ServerWebExchangeMatchercreateDelegate(org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints endpoints) protected final List<org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher> getDelegateMatchers(Set<String> paths, @Nullable org.springframework.http.HttpMethod httpMethod) protected final org.springframework.boot.actuate.endpoint.EndpointIdgetEndpointId(Object source) protected final booleanhasWebServerNamespace(@Nullable org.springframework.context.ApplicationContext applicationContext, org.springframework.boot.actuate.endpoint.web.WebServerNamespace webServerNamespace) protected booleanignoreApplicationContext(@Nullable org.springframework.context.ApplicationContext applicationContext) Returns if theApplicationContextshould be ignored and not used for matching.protected booleanignoreApplicationContext(@Nullable org.springframework.context.ApplicationContext applicationContext, org.springframework.boot.actuate.autoconfigure.web.server.ManagementPortType managementPortType) protected voidinitialized(Supplier<org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints> supplier) Called once the context has been initialized.protected reactor.core.publisher.Mono<org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher.MatchResult> matches(org.springframework.web.server.ServerWebExchange exchange, Supplier<org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints> context) Decides whether the rule implemented by the strategy matches the supplied exchange.toString()protected final StringwithHttpMethod(org.springframework.http.HttpMethod httpMethod) Restricts the matcher to only consider requests with a particular HTTP method.Methods inherited from class ApplicationContextServerWebExchangeMatcher
getContext, matches
-
Method Details
-
withHttpMethod
public EndpointRequest.AdditionalPathsEndpointServerWebExchangeMatcher withHttpMethod(org.springframework.http.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 org.springframework.context.ApplicationContext applicationContext, org.springframework.boot.actuate.autoconfigure.web.server.ManagementPortType managementPortType) -
createDelegate
protected org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher createDelegate(org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints endpoints) -
toString
-
initialized
protected void initialized(Supplier<org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints> supplier) Description copied from class:ApplicationContextServerWebExchangeMatcherCalled once the context has been initialized.- Overrides:
initializedin classApplicationContextServerWebExchangeMatcher<C>- Parameters:
supplier- a supplier for the initialized context (may throw an exception)
-
getDelegateMatchers
-
matches
protected reactor.core.publisher.Mono<org.springframework.security.web.server.util.matcher.ServerWebExchangeMatcher.MatchResult> matches(org.springframework.web.server.ServerWebExchange exchange, Supplier<org.springframework.boot.actuate.endpoint.web.PathMappedEndpoints> context) Description copied from class:ApplicationContextServerWebExchangeMatcherDecides whether the rule implemented by the strategy matches the supplied exchange.- Specified by:
matchesin classApplicationContextServerWebExchangeMatcher<C>- Parameters:
exchange- the source exchangecontext- a supplier for the initialized context (may throw an exception)- Returns:
- if the exchange matches
-
ignoreApplicationContext
protected boolean ignoreApplicationContext(@Nullable org.springframework.context.ApplicationContext applicationContext) Description copied from class:ApplicationContextServerWebExchangeMatcherReturns if theApplicationContextshould be ignored and not used for matching. If this method returnstruethen the context will not be used and thematchesmethod will returnfalse.- Overrides:
ignoreApplicationContextin classApplicationContextServerWebExchangeMatcher<C>- Parameters:
applicationContext- the candidate application context- Returns:
- if the application context should be ignored
-
hasWebServerNamespace
protected final boolean hasWebServerNamespace(@Nullable org.springframework.context.ApplicationContext applicationContext, org.springframework.boot.actuate.endpoint.web.WebServerNamespace webServerNamespace) -
toString
-
getEndpointId
-