Interface HttpCommonAttributesGetter<REQUEST,RESPONSE>
- All Known Subinterfaces:
HttpClientAttributesGetter<REQUEST,,RESPONSE> HttpServerAttributesGetter<REQUEST,RESPONSE>
-
Method Summary
Modifier and TypeMethodDescriptiondefault StringgetRequestHeader(REQUEST request, String name) Extracts all values of header namednamefrom the request, or an empty list if there were none.getResponseHeader(REQUEST request, RESPONSE response, String name) Extracts all values of header namednamefrom the response, or an empty list if there were none.default IntegergetStatusCode(REQUEST request, RESPONSE response, Throwable error) Extracts thehttp.status_codespan attribute.default StringDeprecated.requestHeader(REQUEST request, String name) Deprecated.UsegetRequestHeader(Object, String)instead.responseHeader(REQUEST request, RESPONSE response, String name) Deprecated.UsegetResponseHeader(Object, Object, String)instead.default IntegerstatusCode(REQUEST request, RESPONSE response, Throwable error) Deprecated.UsegetStatusCode(Object, Object, Throwable)instead.
-
Method Details
-
getMethod
-
method
Deprecated.UsegetMethod(Object)instead.This method is deprecated and will be removed in the subsequent release. -
getRequestHeader
Extracts all values of header namednamefrom the request, or an empty list if there were none.Implementations of this method must not return a null value; an empty list should be returned instead.
-
requestHeader
Deprecated.UsegetRequestHeader(Object, String)instead.Extracts all values of header namednamefrom the request, or an empty list if there were none.Implementations of this method must not return a null value; an empty list should be returned instead.
This method is deprecated and will be removed in the subsequent release.
-
getStatusCode
@Nullable default Integer getStatusCode(REQUEST request, RESPONSE response, @Nullable Throwable error) Extracts thehttp.status_codespan attribute.This is called from
Instrumenter.end(Context, Object, Object, Throwable), only whenresponseis non-null. -
statusCode
@Deprecated @Nullable default Integer statusCode(REQUEST request, RESPONSE response, @Nullable Throwable error) Deprecated.UsegetStatusCode(Object, Object, Throwable)instead.Extracts thehttp.status_codespan attribute.This is called from
Instrumenter.end(Context, Object, Object, Throwable), only whenresponseis non-null.This method is deprecated and will be removed in the subsequent release.
-
getResponseHeader
Extracts all values of header namednamefrom the response, or an empty list if there were none.This is called from
Instrumenter.end(Context, Object, Object, Throwable), only whenresponseis non-null.Implementations of this method must not return a null value; an empty list should be returned instead.
-
responseHeader
Deprecated.UsegetResponseHeader(Object, Object, String)instead.Extracts all values of header namednamefrom the response, or an empty list if there were none.This is called from
Instrumenter.end(Context, Object, Object, Throwable), only whenresponseis non-null.Implementations of this method must not return a null value; an empty list should be returned instead.
This method is deprecated and will be removed in the subsequent release.
-
getMethod(Object)instead.