@NonNullApi
public final class WebMvcTags
extends java.lang.Object
Tags associated with a request-response exchange that
is instrumented by WebMvcMetricsFilter.| Modifier and Type | Method and Description |
|---|---|
static io.micrometer.core.instrument.Tag |
exception(java.lang.Throwable exception)
Creates a
exception tag based on the simple
name of the class of the given exception. |
static io.micrometer.core.instrument.Tag |
method(javax.servlet.http.HttpServletRequest request)
Creates a
method tag based on the method of the given request. |
static io.micrometer.core.instrument.Tag |
status(javax.servlet.http.HttpServletResponse response)
Creates a
method tag based on the status of the given response. |
static io.micrometer.core.instrument.Tag |
uri(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Creates a
uri tag based on the URI of the given request. |
public static io.micrometer.core.instrument.Tag method(@Nullable
javax.servlet.http.HttpServletRequest request)
method tag based on the method of the given request.request - the requestpublic static io.micrometer.core.instrument.Tag status(@Nullable
javax.servlet.http.HttpServletResponse response)
method tag based on the status of the given response.response - the HTTP responsepublic static io.micrometer.core.instrument.Tag uri(@Nullable
javax.servlet.http.HttpServletRequest request,
@Nullable
javax.servlet.http.HttpServletResponse response)
uri tag based on the URI of the given request. Uses the
HandlerMapping.BEST_MATCHING_PATTERN_ATTRIBUTE best matching pattern if
available, falling back to the request's path info if necessary.request - the requestresponse - the responsepublic static io.micrometer.core.instrument.Tag exception(@Nullable
java.lang.Throwable exception)
exception tag based on the simple
name of the class of the given exception.exception - the exception, may be null