Uses of Class
brave.Span
| Package | Description |
|---|---|
| brave | |
| brave.propagation |
-
Uses of Span in brave
Methods in brave that return Span Modifier and Type Method Description abstract SpanSpan. annotate(long timestamp, String value)Likeannotate(String), except with a given timestamp in microseconds.abstract SpanSpan. annotate(String value)Associates an event that explains latency with the current system time.SpanTracer. currentSpan()Returns the current span in scope or null if there isn't one.abstract SpanSpan. error(Throwable throwable)Records an error that impacted this operation.SpanTracer. joinSpan(TraceContext context)Joining is re-using the same trace and span ids extracted from an incoming RPC request.abstract SpanSpan. kind(Span.Kind kind)When present, the span is remote.abstract SpanSpan. name(String name)Sets the string name for the logical operation this span represents.SpanTracer. newChild(TraceContext parent)Explicitly creates a child within an existing trace.SpanTracer. newTrace()Explicitly creates a new trace.SpanTracer. nextSpan()Returns a new child span if there's aTracer.currentSpan()or a new trace if there isn't.SpanTracer. nextSpan(TraceContextOrSamplingFlags extracted)This creates a new span based on parameters extracted from an incoming request.<T> SpanTracer. nextSpan(SamplerFunction<T> samplerFunction, T arg)LikeTracer.nextSpan()except when there is no trace in process, the samplertriggersagainst the supplied argument.<T> SpanTracer. nextSpanWithParent(SamplerFunction<T> samplerFunction, T arg, TraceContext parent)LikeTracer.nextSpan(SamplerFunction, Object)except this controls the parent context explicitly.SpanSpan. remoteEndpoint(zipkin2.Endpoint endpoint)Deprecated.Since 5.0, useremoteServiceName(String)remoteIpAndPort(String, int).abstract SpanSpan. remoteServiceName(String remoteServiceName)Lower-case label of the remote node in the service graph, such as "favstar".abstract SpanSpan. start()Starts the span with an implicit timestamp.abstract SpanSpan. start(long timestamp)Likestart(), except with a given timestamp in microseconds.abstract SpanSpan. tag(String key, String value)Tags give your span context for search, viewing and analysis.SpanTracer. toSpan(TraceContext context)Converts the context to a Span object after decorating it for propagation.Methods in brave with parameters of type Span Modifier and Type Method Description voidTag. tag(I input, Span span)Tags the value parsed from theinput.Tracer.SpanInScopeTracer. withSpanInScope(Span span)Makes the given span the "current span" and returns an object that exits that scope on close. -
Uses of Span in brave.propagation
Methods in brave.propagation that return Span Modifier and Type Method Description SpanThreadLocalSpan. next()Returns theTracer.nextSpan()or null ifThreadLocalSpan.CURRENT_TRACERand tracing isn't available.SpanThreadLocalSpan. next(TraceContextOrSamplingFlags extracted)Returns theTracer.nextSpan(TraceContextOrSamplingFlags)or null ifThreadLocalSpan.CURRENT_TRACERand tracing isn't available.SpanThreadLocalSpan. remove()Returns the span set in scope viaThreadLocalSpan.next()or null if there was none.