Provides application work queue and worker threads. More...
#include <TableScannerQueue.h>
Public Member Functions | |
TableScannerQueue () | |
Default constructor. More... | |
~TableScannerQueue () | |
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 | next_result (ScanCellsPtr &cells, int *error, std::string &error_msg) |
void | add_cells (ScanCellsPtr &cells) |
void | set_error (int error, const std::string &error_msg) |
Private Types | |
typedef std::list < ApplicationHandler * > | WorkQueue |
typedef std::list< ScanCellsPtr > | CellsQueue |
Private Attributes | |
std::mutex | m_mutex |
std::condition_variable | m_cond |
WorkQueue | m_work_queue |
CellsQueue | m_cells_queue |
std::string | m_error_msg |
int | m_error {} |
bool | m_error_shown {} |
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 40 of file TableScannerQueue.h.
|
private |
Definition at line 113 of file TableScannerQueue.h.
|
private |
Definition at line 112 of file TableScannerQueue.h.
|
inline |
Default constructor.
Definition at line 46 of file TableScannerQueue.h.
|
inline |
Definition at line 48 of file TableScannerQueue.h.
|
inlinevirtual |
Adds an application handler to queue.
Implements Hypertable::ApplicationQueueInterface.
Definition at line 52 of file TableScannerQueue.h.
|
inline |
Definition at line 97 of file TableScannerQueue.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 58 of file TableScannerQueue.h.
|
inline |
Definition at line 60 of file TableScannerQueue.h.
|
inline |
Definition at line 103 of file TableScannerQueue.h.
|
private |
Definition at line 117 of file TableScannerQueue.h.
|
private |
Definition at line 115 of file TableScannerQueue.h.
|
private |
Definition at line 119 of file TableScannerQueue.h.
|
private |
Definition at line 118 of file TableScannerQueue.h.
|
private |
Definition at line 120 of file TableScannerQueue.h.
|
private |
Definition at line 114 of file TableScannerQueue.h.
|
private |
Definition at line 116 of file TableScannerQueue.h.