Class NetworkAttributesExtractor<REQUEST,RESPONSE>
java.lang.Object
io.opentelemetry.instrumentation.api.instrumenter.network.NetworkAttributesExtractor<REQUEST,RESPONSE>
- All Implemented Interfaces:
io.opentelemetry.instrumentation.api.instrumenter.AttributesExtractor<REQUEST,RESPONSE>
public final class NetworkAttributesExtractor<REQUEST,RESPONSE>
extends Object
implements io.opentelemetry.instrumentation.api.instrumenter.AttributesExtractor<REQUEST,RESPONSE>
Extractor of network
attributes.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <REQUEST,RESPONSE>
NetworkAttributesExtractor<REQUEST,RESPONSE> create(NetworkAttributesGetter<REQUEST, RESPONSE> getter) Returns a newNetworkAttributesExtractorthat will use the passedNetworkAttributesGetter.voidonEnd(io.opentelemetry.api.common.AttributesBuilder attributes, io.opentelemetry.context.Context context, REQUEST request, RESPONSE response, Throwable error) voidonStart(io.opentelemetry.api.common.AttributesBuilder attributes, io.opentelemetry.context.Context parentContext, REQUEST request)
-
Method Details
-
create
public static <REQUEST,RESPONSE> NetworkAttributesExtractor<REQUEST,RESPONSE> create(NetworkAttributesGetter<REQUEST, RESPONSE> getter) Returns a newNetworkAttributesExtractorthat will use the passedNetworkAttributesGetter. -
onStart
public void onStart(io.opentelemetry.api.common.AttributesBuilder attributes, io.opentelemetry.context.Context parentContext, REQUEST request) -
onEnd
-