Class ThresholdInternalSpan
- java.lang.Object
-
- com.couchbase.client.core.cnc.tracing.ThresholdInternalSpan
-
- All Implemented Interfaces:
InternalSpan
public class ThresholdInternalSpan extends Object implements InternalSpan
Provides the basic span implementation for theThresholdRequestTracer
.Most of these span methods are stubs since all the threshold tracer cares about is when the operation is complete if it is over threshold.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
finish()
Finishes the overall request span (does not touch or change any sub-spans).RequestContext
requestContext()
Returns the request context so it can be accessed once set, usually by the tracer implementation.void
requestContext(RequestContext ctx)
Called by the system once the request is created and gives the span a chance to look into request specific information.void
startDispatch()
Signals the start of the IO network dispatch phase for this request.void
startPayloadEncoding()
Signals the start of payload encoding, if needed for this request.void
stopDispatch()
Signals the end of the IO network dispatch phase for this request.void
stopPayloadEncoding()
Signals the end of payload encoding, if needed for this request.RequestSpan
toRequestSpan()
Returns a request span that wraps the internal span.
-
-
-
Method Detail
-
finish
public void finish()
Description copied from interface:InternalSpan
Finishes the overall request span (does not touch or change any sub-spans).- Specified by:
finish
in interfaceInternalSpan
-
requestContext
public void requestContext(RequestContext ctx)
Description copied from interface:InternalSpan
Called by the system once the request is created and gives the span a chance to look into request specific information.- Specified by:
requestContext
in interfaceInternalSpan
- Parameters:
ctx
- the request context once available.
-
requestContext
public RequestContext requestContext()
Description copied from interface:InternalSpan
Returns the request context so it can be accessed once set, usually by the tracer implementation.- Specified by:
requestContext
in interfaceInternalSpan
-
startDispatch
public void startDispatch()
Description copied from interface:InternalSpan
Signals the start of the IO network dispatch phase for this request.- Specified by:
startDispatch
in interfaceInternalSpan
-
stopDispatch
public void stopDispatch()
Description copied from interface:InternalSpan
Signals the end of the IO network dispatch phase for this request.- Specified by:
stopDispatch
in interfaceInternalSpan
-
startPayloadEncoding
public void startPayloadEncoding()
Description copied from interface:InternalSpan
Signals the start of payload encoding, if needed for this request.- Specified by:
startPayloadEncoding
in interfaceInternalSpan
-
stopPayloadEncoding
public void stopPayloadEncoding()
Description copied from interface:InternalSpan
Signals the end of payload encoding, if needed for this request.- Specified by:
stopPayloadEncoding
in interfaceInternalSpan
-
toRequestSpan
public RequestSpan toRequestSpan()
Description copied from interface:InternalSpan
Returns a request span that wraps the internal span.- Specified by:
toRequestSpan
in interfaceInternalSpan
-
-