|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.accumulo.cloudtrace.instrument.impl.MilliSpan
public class MilliSpan
A Span implementation that stores its information in milliseconds since the epoch.
| Field Summary |
|---|
| Fields inherited from interface org.apache.accumulo.cloudtrace.instrument.Span |
|---|
ROOT_SPAN_ID |
| Constructor Summary | |
|---|---|
MilliSpan(String description,
long id,
Span parent)
|
|
| Method Summary | |
|---|---|
long |
accumulatedMillis()
Return the total amount of time elapsed since start was called, if running, or difference between stop and start |
Span |
child(String description)
Create a child span of this span with the given description |
protected long |
currentTimeMillis()
|
void |
data(String key,
String value)
Add data associated with this span |
String |
description()
Return a textual description of this span |
Map<String,String> |
getData()
Get data associated with this span (read only) |
long |
getStartTimeMillis()
Get the start time, in milliseconds |
long |
getStopTimeMillis()
Get the stop time, in milliseconds |
Span |
parent()
The parent span: returns null if this is the root span |
long |
parentId()
Return the pseudo-unique (random) number of the parent span, returns ROOT_SPAN_ID if this is the root span |
boolean |
running()
Has the span been started and not yet stopped? |
long |
spanId()
A pseudo-unique (random) number assigned to this span instance |
void |
start()
Begin gathering timing information |
void |
stop()
The block has completed, stop the clock |
String |
toString()
|
long |
traceId()
A pseudo-unique (random) number assigned to the trace associated with this span |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MilliSpan(String description,
long id,
Span parent)
| Method Detail |
|---|
public Span child(String description)
Span
child in interface Spanpublic void start()
Span
start in interface Spanpublic void stop()
Span
stop in interface Spanprotected long currentTimeMillis()
public boolean running()
Span
running in interface Spanpublic long accumulatedMillis()
Span
accumulatedMillis in interface Spanpublic String toString()
toString in interface SpantoString in class Objectpublic String description()
Span
description in interface Spanpublic long spanId()
Span
spanId in interface Spanpublic Span parent()
Span
parent in interface Spanpublic long parentId()
Span
parentId in interface Spanpublic long traceId()
Span
traceId in interface Spanpublic long getStartTimeMillis()
Span
getStartTimeMillis in interface Spanpublic long getStopTimeMillis()
Span
getStopTimeMillis in interface Span
public void data(String key,
String value)
Span
data in interface Spanpublic Map<String,String> getData()
Span
getData in interface Span
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||