Class JobQueue
- java.lang.Object
-
- org.opendaylight.infrautils.jobcoordinator.internal.JobQueue
-
public class JobQueue extends Object
A queue which holds job entries and the current running job.
-
-
Constructor Summary
Constructors Constructor Description JobQueue()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddEntry(org.opendaylight.infrautils.jobcoordinator.internal.JobEntry entry)@Nullable org.opendaylight.infrautils.jobcoordinator.internal.JobEntrygetExecutingEntry()intgetFinishedJobCount()doublegetJobQueueMovingAverageExecutionTime()intgetPendingJobCount()StringgetQueueId()booleanisEmpty()voidonJobFinished(long timeTaken)@Nullable org.opendaylight.infrautils.jobcoordinator.internal.JobEntrypoll()voidsetExecutingEntry(@Nullable org.opendaylight.infrautils.jobcoordinator.internal.JobEntry executingEntry)StringtoString()
-
-
-
Method Detail
-
addEntry
public void addEntry(org.opendaylight.infrautils.jobcoordinator.internal.JobEntry entry)
-
isEmpty
public boolean isEmpty()
-
poll
public @Nullable org.opendaylight.infrautils.jobcoordinator.internal.JobEntry poll()
-
getExecutingEntry
public @Nullable org.opendaylight.infrautils.jobcoordinator.internal.JobEntry getExecutingEntry()
-
setExecutingEntry
public void setExecutingEntry(@Nullable org.opendaylight.infrautils.jobcoordinator.internal.JobEntry executingEntry)
-
getQueueId
public String getQueueId()
-
onJobFinished
public void onJobFinished(long timeTaken)
-
getPendingJobCount
public int getPendingJobCount()
-
getFinishedJobCount
public int getFinishedJobCount()
-
getJobQueueMovingAverageExecutionTime
public double getJobQueueMovingAverageExecutionTime()
-
-