public class JobTiming extends Object implements Clock.ClockUpdateListener
| Constructor and Description |
|---|
JobTiming(RouterContext context) |
| Modifier and Type | Method and Description |
|---|---|
void |
end()
Mark the job as finished, recording the current time as the actual end time.
|
long |
getActualEnd()
Get the actual end time when the job finished execution.
|
long |
getActualEndNanos()
Get the nanosecond-precision end time when the job finished execution.
|
long |
getActualStart()
Get the actual start time when the job began execution.
|
long |
getActualStartNanos()
Get the nanosecond-precision start time when the job began execution.
|
double |
getDurationMillis()
Get the execution duration in milliseconds with sub-millisecond precision.
|
double |
getPendingMillis()
Get the pending/wait time in milliseconds with sub-millisecond precision.
|
long |
getStartAfter()
Get the scheduled start time for the job.
|
void |
offsetChanged(long delta)
Adjust all timing values by the specified delta.
|
void |
setActualEnd(long actualEndTime)
Set the actual end time when the job finished execution.
|
void |
setActualStart(long actualStartTime)
Set the actual start time when the job began execution.
|
void |
setStartAfter(long startTime)
Set the scheduled start time for the job.
|
void |
start()
Mark the job as started, recording the current time as the actual start time.
|
public JobTiming(RouterContext context)
public void end()
public long getActualEnd()
public long getActualEndNanos()
public long getActualStart()
public long getActualStartNanos()
public double getDurationMillis()
public double getPendingMillis()
public long getStartAfter()
public void offsetChanged(long delta)
offsetChanged in interface Clock.ClockUpdateListenerdelta - milliseconds to add to all timing values (positive or negative)public void setActualEnd(long actualEndTime)
actualEndTime - milliseconds after the epoch when the job actually endedpublic void setActualStart(long actualStartTime)
actualStartTime - milliseconds after the epoch when the job actually startedpublic void setStartAfter(long startTime)
startTime - milliseconds after the epoch when the job should startpublic void start()