Class WebMvcTags
java.lang.Object
org.springframework.boot.actuate.metrics.web.servlet.WebMvcTags
Deprecated, for removal: This API element is subject to removal in a future version.
Factory methods for
Tags
associated with a request-response exchange that
is handled by Spring MVC.- Since:
- 2.0.0
- Author:
- Jon Schneider, Andy Wilkinson, Brian Clozel, Michael McFadyen
-
Method Summary
Modifier and TypeMethodDescriptionstatic io.micrometer.core.instrument.Tag
Deprecated, for removal: This API element is subject to removal in a future version.static io.micrometer.core.instrument.Tag
method
(HttpServletRequest request) Deprecated, for removal: This API element is subject to removal in a future version.static io.micrometer.core.instrument.Tag
outcome
(HttpServletResponse response) Deprecated, for removal: This API element is subject to removal in a future version.Creates anoutcome
tag based on the status of the givenresponse
.static io.micrometer.core.instrument.Tag
status
(HttpServletResponse response) Deprecated, for removal: This API element is subject to removal in a future version.Creates astatus
tag based on the status of the givenresponse
.static io.micrometer.core.instrument.Tag
uri
(HttpServletRequest request, HttpServletResponse response) Deprecated, for removal: This API element is subject to removal in a future version.Creates auri
tag based on the URI of the givenrequest
.static io.micrometer.core.instrument.Tag
uri
(HttpServletRequest request, HttpServletResponse response, boolean ignoreTrailingSlash) Deprecated, for removal: This API element is subject to removal in a future version.Creates auri
tag based on the URI of the givenrequest
.
-
Method Details
-
method
Deprecated, for removal: This API element is subject to removal in a future version.- Parameters:
request
- the request- Returns:
- the method tag whose value is a capitalized method (e.g. GET).
-
status
Deprecated, for removal: This API element is subject to removal in a future version.Creates astatus
tag based on the status of the givenresponse
.- Parameters:
response
- the HTTP response- Returns:
- the status tag derived from the status of the response
-
uri
public static io.micrometer.core.instrument.Tag uri(HttpServletRequest request, HttpServletResponse response) Deprecated, for removal: This API element is subject to removal in a future version.Creates auri
tag based on the URI of the givenrequest
. Uses theHandlerMapping.BEST_MATCHING_PATTERN_ATTRIBUTE
best matching pattern if available. Falling back toREDIRECTION
for 3xx responses,NOT_FOUND
for 404 responses,root
for requests with no path info, andUNKNOWN
for all other requests.- Parameters:
request
- the requestresponse
- the response- Returns:
- the uri tag derived from the request
-
uri
public static io.micrometer.core.instrument.Tag uri(HttpServletRequest request, HttpServletResponse response, boolean ignoreTrailingSlash) Deprecated, for removal: This API element is subject to removal in a future version.Creates auri
tag based on the URI of the givenrequest
. Uses theHandlerMapping.BEST_MATCHING_PATTERN_ATTRIBUTE
best matching pattern if available. Falling back toREDIRECTION
for 3xx responses,NOT_FOUND
for 404 responses,root
for requests with no path info, andUNKNOWN
for all other requests.- Parameters:
request
- the requestresponse
- the responseignoreTrailingSlash
- whether to ignore the trailing slash- Returns:
- the uri tag derived from the request
-
exception
Deprecated, for removal: This API element is subject to removal in a future version.- Parameters:
exception
- the exception, may benull
- Returns:
- the exception tag derived from the exception
-
outcome
Deprecated, for removal: This API element is subject to removal in a future version.Creates anoutcome
tag based on the status of the givenresponse
.- Parameters:
response
- the HTTP response- Returns:
- the outcome tag derived from the status of the response
- Since:
- 2.1.0
-
ServerRequestObservationConvention