Encapsulates asynchronous buffered block writing engine.
More...
#include <buf_writer.h>
|
typedef block_type::bid_type | bid_type |
|
typedef std::priority_queue
< batch_entry, std::vector
< batch_entry >
, batch_entry_cmp > | batch_type |
|
|
const unsigned_type | nwriteblocks |
|
block_type * | write_buffers |
|
bid_type * | write_bids |
|
request_ptr * | write_reqs |
|
const unsigned_type | writebatchsize |
|
std::vector< int_type > | free_write_blocks |
|
std::vector< int_type > | busy_write_blocks |
|
batch_type | batch_write_blocks |
|
template<typename block_type>
class buffered_writer< block_type >
Encapsulates asynchronous buffered block writing engine.
buffered_writer
overlaps I/Os with filling of output buffer.
template<typename block_type>
Constructs an object.
- Parameters
-
write_buf_size | number of write buffers to use |
write_batch_size | number of blocks to accumulate in order to flush write requests (bulk buffered writing) |
template<typename block_type>
Flushes not yet written buffers and frees used memory.
template<typename block_type>
Flushes not yet written buffers.
template<typename block_type>
template<typename block_type>
block_type* buffered_writer< block_type >::write |
( |
block_type * |
filled_block, |
|
|
const bid_type & |
bid |
|
) |
| |
|
inline |
Submits block for writing.
- Parameters
-
filled_block | pointer to the block |
- Parameters
-
bid | block identifier, a place to write data of the filled_block |
- Returns
- pointer to the new free block from the pool
The documentation for this class was generated from the following file: