Class JettyClientTags
java.lang.Object
io.micrometer.core.instrument.binder.jetty.JettyClientTags
public final class JettyClientTags
extends java.lang.Object
Factory methods for
Tags
associated with a request-response exchange that
is handled by Jetty HttpClient
.- Since:
- 1.5.0
-
Method Summary
Modifier and Type Method Description static Tag
exception(org.eclipse.jetty.client.api.Result result)
Creates anexception
tag based on thesimple name
of the class of the givenexception
.static Tag
method(org.eclipse.jetty.client.api.Request request)
Creates amethod
tag based on themethod
of the givenrequest
.static Tag
outcome(org.eclipse.jetty.client.api.Result result)
Creates anoutcome
tag based on the status of the givenresult
.static Tag
status(org.eclipse.jetty.client.api.Result result)
Creates astatus
tag based on the status of the givenresult
.static Tag
uri(org.eclipse.jetty.client.api.Result result, java.util.function.Function<org.eclipse.jetty.client.api.Result,java.lang.String> successfulUriPattern)
Creates auri
tag based on the URI of the givenresult
.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Method Details
-
method
Creates amethod
tag based on themethod
of the givenrequest
.- Parameters:
request
- the request- Returns:
- the method tag whose value is a capitalized method (e.g. GET).
-
status
Creates astatus
tag based on the status of the givenresult
.- Parameters:
result
- the request result- Returns:
- the status tag derived from the status of the response
-
uri
public static Tag uri(org.eclipse.jetty.client.api.Result result, java.util.function.Function<org.eclipse.jetty.client.api.Result,java.lang.String> successfulUriPattern)Creates auri
tag based on the URI of the givenresult
.REDIRECTION
for 3xx responses,NOT_FOUND
for 404 responses.- Parameters:
result
- the request resultsuccessfulUriPattern
- successful URI pattern- Returns:
- the uri tag derived from the request result
-
exception
Creates anexception
tag based on thesimple name
of the class of the givenexception
.- Parameters:
result
- the request result- Returns:
- the exception tag derived from the exception
-
outcome
Creates anoutcome
tag based on the status of the givenresult
.- Parameters:
result
- the request result- Returns:
- the outcome tag derived from the status of the response
-