public class UimaVmQueue extends LinkedBlockingQueue<Runnable> implements UimaVmQueueMBean
LinkedBlockingQueue. It exposes the following queue
statistics:
| Constructor and Description |
|---|
UimaVmQueue() |
| Modifier and Type | Method and Description |
|---|---|
int |
getConsumerCount()
Returns total number of concurrent threads consuming work from this queue.
|
long |
getDequeueCount()
Returns total number of items dequeued so far
|
int |
getQueueSize()
Returns the current number of items in the queue.
|
void |
reset()
Resets both the queue size and dequeue count to zero
|
void |
setConsumerCount(int aConsumerCount)
Sets the number of concurrent threads consuming work from this queue
|
Runnable |
take()
Override of the method in the super class to enable counting of items taken (dequeued) off the
queue.
|
clear, contains, drainTo, drainTo, iterator, offer, offer, peek, poll, poll, put, remainingCapacity, remove, size, spliterator, toArray, toArray, toStringadd, addAll, element, removecontainsAll, isEmpty, removeAll, retainAllclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddaddAll, containsAll, equals, hashCode, isEmpty, parallelStream, removeAll, removeIf, retainAll, streampublic int getQueueSize()
getQueueSize in interface UimaVmQueueMBeanpublic long getDequeueCount()
getDequeueCount in interface UimaVmQueueMBeanpublic Runnable take() throws InterruptedException
take in interface BlockingQueue<Runnable>take in class LinkedBlockingQueue<Runnable>InterruptedExceptionpublic int getConsumerCount()
getConsumerCount in interface UimaVmQueueMBeanpublic void setConsumerCount(int aConsumerCount)
aConsumerCount - - number of consuming threadspublic void reset()
reset in interface UimaVmQueueMBeanCopyright © 2016. All rights reserved.