public static interface WorkContinuationInstrumenter.Instrumenter
Modifier and Type | Method and Description |
---|---|
boolean |
isTracing()
Allows to know in advance if the custom instrumenter desires to receive continuation updates.
|
void |
markFailure(Object token,
Throwable th)
Reports a failure while executing work.
|
Object |
onAskForWorkToContinue(String tag)
Captures when asking for work to be stolen.
|
Object |
onBeginWorkContinuation(String tag,
Object token)
Captures the beginning of the continuation for stolen work.
|
void |
onEndWorkContinuation(Object token)
Captures the end of the continuation for stolen work.
|
Object |
onOfferWorkForContinuation(String tag)
Tracks when some work is ready to offered for continuation.
|
Object |
onOfferWorkForContinuation(String tag,
Object token)
Tracks when some work is ready to be stolen.
|
boolean isTracing()
Object onAskForWorkToContinue(String tag)
tag
- name.Object onOfferWorkForContinuation(String tag)
tag
- name.Object onOfferWorkForContinuation(String tag, Object token)
tag
- name (optional).token
- returned by onAskForWorkToContinue(java.lang.String)
.Object onBeginWorkContinuation(String tag, Object token)
tag
- name (optional).token
- returned by onOfferWorkForContinuation(java.lang.String)
.void onEndWorkContinuation(Object token)
token
- returned by onBeginWorkContinuation(java.lang.String, java.lang.Object)
.void markFailure(Object token, Throwable th)
onEndWorkContinuation(Object)
(Object)} still needs to be
invoked.
token
- returned by onBeginWorkContinuation(String, Object)
(Object, String)}.th
- containing the failure.