Provides application work queue and worker threads. More...
#include <TableMutatorQueue.h>
Public Member Functions | |
TableMutatorQueue (std::mutex &mutex, std::condition_variable &cond) | |
~TableMutatorQueue () | |
virtual void | add (ApplicationHandler *app_handler) |
Adds an application handler to queue. More... | |
virtual void | add_unlocked (ApplicationHandler *app_handler) |
Adds an application handler to queue without locking. More... | |
void | wait_for_buffer (std::unique_lock< std::mutex > &lock, ApplicationHandler **app_handlerp) |
Private Types | |
typedef std::list < ApplicationHandler * > | WorkQueue |
Private Attributes | |
std::mutex & | m_mutex |
std::condition_variable & | m_cond |
WorkQueue | m_work_queue |
Provides application work queue and worker threads.
It maintains a queue of requests and a pool of threads that pull requests off the queue and carry them out.
Definition at line 42 of file TableMutatorQueue.h.
|
private |
Definition at line 74 of file TableMutatorQueue.h.
|
inline |
Definition at line 49 of file TableMutatorQueue.h.
|
inline |
Definition at line 51 of file TableMutatorQueue.h.
|
inlinevirtual |
Adds an application handler to queue.
Implements Hypertable::ApplicationQueueInterface.
Definition at line 55 of file TableMutatorQueue.h.
|
inlinevirtual |
Adds an application handler to queue without locking.
This method is similar to add except that it does not do any locking to serialize access to the queue. It is for situations where access serialization is handled by the caller.
Implements Hypertable::ApplicationQueueInterface.
Definition at line 60 of file TableMutatorQueue.h.
|
inline |
Definition at line 65 of file TableMutatorQueue.h.
|
private |
Definition at line 76 of file TableMutatorQueue.h.
|
private |
Definition at line 75 of file TableMutatorQueue.h.
|
private |
Definition at line 77 of file TableMutatorQueue.h.