public final class TimeTracker extends Object
Check state both when entering and exiting, to allow for arbitrary new queries anywhere inside a search chain.
Modifier and Type | Class and Description |
---|---|
static class |
TimeTracker.Activity |
(package private) static class |
TimeTracker.SearcherTimer |
(package private) static class |
TimeTracker.State |
(package private) static class |
TimeTracker.Tag |
(package private) static class |
TimeTracker.TimeSource |
Modifier and Type | Field and Description |
---|---|
private int |
entryIndex |
private boolean |
invoking |
private long |
last |
private com.yahoo.component.chain.Chain<? extends com.yahoo.processing.Processor> |
searchChain |
private TimeTracker.SearcherTimer[] |
searcherTracking |
private TimeTracker.State |
state |
private List<TimeTracker.Tag> |
tags |
(package private) TimeTracker.TimeSource |
timeSource |
Constructor and Description |
---|
TimeTracker(com.yahoo.component.chain.Chain<? extends com.yahoo.processing.Processor> searchChain,
int entryIndex) |
TimeTracker(com.yahoo.component.chain.Chain<? extends Searcher> searchChain) |
Modifier and Type | Method and Description |
---|---|
private void |
concludeState(long now) |
private void |
concludeStateOnExit(long now) |
private long |
detailedMeasurements(int searcherIndex,
boolean calledAsInvoking) |
private void |
enteringState(int searcherIndex,
boolean detailed,
TimeTracker.Activity activity) |
private long |
fetchTime(TimeTracker.Activity filter,
TimeTracker.Tag container) |
long |
fillTime() |
long |
first() |
long |
firstFill() |
private TimeTracker.Activity |
getActivity() |
private ElapsedTime |
getElapsedTime(Pong p) |
private ElapsedTime |
getElapsedTime(Result r) |
private long |
getNow() |
private TimeTracker.SearcherTimer |
getPreviouslyRunSearcher(int searcherIndex,
boolean calledAsInvoking) |
private void |
initBreakdown() |
private void |
initNewState(long now,
TimeTracker.Activity activity) |
(package private) void |
injectTimeSource(TimeTracker.TimeSource source) |
private boolean |
isNewState(TimeTracker.Activity callPath) |
long |
last() |
long |
pingTime() |
private long |
returnfromState(int searcherIndex,
boolean detailed) |
void |
sampleFill(int searcherIndex,
boolean detailed) |
void |
sampleFillReturn(int searcherIndex,
boolean detailed,
Result annotationReference) |
void |
samplePing(int searcherIndex,
boolean detailed) |
void |
samplePingReturn(int searcherIndex,
boolean detailed,
Pong annotationReference) |
private void |
sampleReturn(int searcherIndex,
boolean detailed,
ElapsedTime elapsed) |
void |
sampleSearch(int searcherIndex,
boolean detailed) |
void |
sampleSearchReturn(int searcherIndex,
boolean detailed,
Result annotationReference) |
(package private) TimeTracker.SearcherTimer[] |
searcherTracking() |
long |
searchTime() |
long |
totalTime() |
private long |
typedSum(TimeTracker.Activity activity) |
private TimeTracker.State state
private List<TimeTracker.Tag> tags
private TimeTracker.SearcherTimer[] searcherTracking
private final com.yahoo.component.chain.Chain<? extends com.yahoo.processing.Processor> searchChain
private boolean invoking
private long last
private final int entryIndex
TimeTracker.TimeSource timeSource
public TimeTracker(com.yahoo.component.chain.Chain<? extends Searcher> searchChain)
public TimeTracker(com.yahoo.component.chain.Chain<? extends com.yahoo.processing.Processor> searchChain, int entryIndex)
private void concludeState(long now)
private void concludeStateOnExit(long now)
private long detailedMeasurements(int searcherIndex, boolean calledAsInvoking)
private void enteringState(int searcherIndex, boolean detailed, TimeTracker.Activity activity)
private long fetchTime(TimeTracker.Activity filter, TimeTracker.Tag container)
public long fillTime()
public long first()
public long firstFill()
private TimeTracker.Activity getActivity()
private long getNow()
private TimeTracker.SearcherTimer getPreviouslyRunSearcher(int searcherIndex, boolean calledAsInvoking)
private void initBreakdown()
private void initNewState(long now, TimeTracker.Activity activity)
void injectTimeSource(TimeTracker.TimeSource source)
private boolean isNewState(TimeTracker.Activity callPath)
public long last()
public long pingTime()
private long returnfromState(int searcherIndex, boolean detailed)
public void sampleFill(int searcherIndex, boolean detailed)
public void sampleFillReturn(int searcherIndex, boolean detailed, Result annotationReference)
public void samplePing(int searcherIndex, boolean detailed)
public void samplePingReturn(int searcherIndex, boolean detailed, Pong annotationReference)
public void sampleSearch(int searcherIndex, boolean detailed)
public void sampleSearchReturn(int searcherIndex, boolean detailed, Result annotationReference)
private void sampleReturn(int searcherIndex, boolean detailed, ElapsedTime elapsed)
private ElapsedTime getElapsedTime(Result r)
private ElapsedTime getElapsedTime(Pong p)
TimeTracker.SearcherTimer[] searcherTracking()
public long searchTime()
public long totalTime()
private long typedSum(TimeTracker.Activity activity)
Copyright © 2017. All rights reserved.