Class RunningSpanStore
java.lang.Object
io.opencensus.trace.export.RunningSpanStore
- Direct Known Subclasses:
InProcessRunningSpanStore, RunningSpanStore.NoopRunningSpanStore
This class allows users to access in-process information about all running spans.
The running spans tracking is available for all the spans with the option Span.Options.RECORD_EVENTS. This functionality allows users to debug stuck
operations or long living operations.
- Since:
- 0.5
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classFilter for running spans.private static final classstatic classSummary of all available data for a span name.static classThe summary of all available data. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static RunningSpanStoreReturns the no-op implementation of theRunningSpanStore.abstract Collection<SpanData> Returns a list of running spans that match theFilter.abstract RunningSpanStore.SummaryReturns the summary of all available data such, as number of running spans.abstract voidsetMaxNumberOfSpans(int maxNumberOfSpans) Sets the maximum number of Spans in thRunningSpanStore.
-
Field Details
-
NOOP_RUNNING_SPAN_STORE
-
-
Constructor Details
-
RunningSpanStore
protected RunningSpanStore()
-
-
Method Details
-
getNoopRunningSpanStore
Returns the no-op implementation of theRunningSpanStore.- Returns:
- the no-op implementation of the
RunningSpanStore.
-
getSummary
Returns the summary of all available data such, as number of running spans.- Returns:
- the summary of all available data.
- Since:
- 0.5
-
getRunningSpans
Returns a list of running spans that match theFilter.- Parameters:
filter- used to filter the returned spans.- Returns:
- a list of running spans that match the
Filter. - Since:
- 0.5
-
setMaxNumberOfSpans
public abstract void setMaxNumberOfSpans(int maxNumberOfSpans) Sets the maximum number of Spans in thRunningSpanStore.0means disabled, by default theRunningSpanStoreis disabled.- Parameters:
maxNumberOfSpans- the maximum number of Spans in thRunningSpanStore.- Throws:
IllegalArgumentException- ifmaxNumberOfSpansis negative.- Since:
- 0.22
-