Access group.
More...
#include <AccessGroup.h>
|
| AccessGroup (const TableIdentifier *identifier, SchemaPtr &schema, AccessGroupSpec *ag_spec, const RangeSpec *range, const Hints *hints=nullptr) |
|
void | add (const Key &key, const ByteString value) |
| Adds a key/value pair. More...
|
|
void | split_row_estimate_data_cached (CellList::SplitRowDataMapT &split_row_data) |
|
void | split_row_estimate_data_stored (CellList::SplitRowDataMapT &split_row_data) |
|
void | populate_cellstore_index_pseudo_table_scanner (CellListScannerBuffer *scanner) |
| Populates scanner with data for .cellstore.index pseudo table. More...
|
|
void | update_schema (SchemaPtr &schema, AccessGroupSpec *ag_spec) |
| Currently supports only adding and deleting column families from AccessGroup. More...
|
|
void | lock () |
|
void | unlock () |
|
MergeScannerAccessGroup * | create_scanner (ScanContext *scan_ctx) |
|
bool | include_in_scan (ScanContext *scan_ctx) |
|
uint64_t | disk_usage () |
|
uint64_t | memory_usage () |
|
void | space_usage (int64_t *memp, int64_t *diskp) |
|
void | load_cellstore (CellStorePtr &cellstore) |
|
void | pre_load_cellstores () |
|
void | post_load_cellstores () |
|
void | measure_garbage (double *total, double *garbage) |
|
void | run_compaction (int maintenance_flags, Hints *hints) |
|
uint64_t | purge_memory (MaintenanceFlag::Map &subtask_map) |
|
MaintenanceData * | get_maintenance_data (ByteArena &arena, time_t now, int flags) |
|
void | stage_compaction () |
|
void | unstage_compaction () |
|
const char * | get_name () |
|
const char * | get_full_name () |
|
void | shrink (String &split_row, bool drop_high, Hints *hints) |
|
void | get_file_data (String &file_list, int64_t *block_countp, bool include_blocked) |
|
void | release_files (const std::vector< String > &files) |
|
void | recovery_initialize () |
|
void | recovery_finalize () |
|
void | dump_keys (std::ofstream &out) |
|
void | dump_garbage_tracker_statistics (std::ofstream &out) |
| Prints human-readable representation of garbage tracker state to an output stream. More...
|
|
void | set_next_csid (uint32_t nid) |
|
void | load_hints (Hints *hints) |
|
String | describe () |
|
Access group.
Definition at line 65 of file AccessGroup.h.
void AccessGroup::add |
( |
const Key & |
key, |
|
|
const ByteString |
value |
|
) |
| |
Adds a key/value pair.
This should be called with the CellCache locked Also, at the end of compaction processing, when m_cell_cache gets reset to a new value, the CellCache should be locked as well.
- Parameters
-
Definition at line 153 of file AccessGroup.cc.
String AccessGroup::describe |
( |
| ) |
|
uint64_t AccessGroup::disk_usage |
( |
| ) |
|
void AccessGroup::dump_garbage_tracker_statistics |
( |
std::ofstream & |
out | ) |
|
Prints human-readable representation of garbage tracker state to an output stream.
This function prints the state of the garbage tracker to out
by calling AccessGroupGarbageTracker::output_state() with the line prefix label being the fully qualified name of the access group.
- Parameters
-
out | Output stream on which to print state |
Definition at line 1248 of file AccessGroup.cc.
void AccessGroup::dump_keys |
( |
std::ofstream & |
out | ) |
|
bool AccessGroup::find_merge_run |
( |
size_t * |
indexp = 0 , |
|
|
size_t * |
lenp = 0 |
|
) |
| |
|
private |
void Hypertable::AccessGroup::get_file_data |
( |
String & |
file_list, |
|
|
int64_t * |
block_countp, |
|
|
bool |
include_blocked |
|
) |
| |
|
inline |
const char* Hypertable::AccessGroup::get_full_name |
( |
| ) |
|
|
inline |
void Hypertable::AccessGroup::get_merge_info |
( |
bool & |
needs_merging, |
|
|
bool & |
end_merge |
|
) |
| |
|
inlineprivate |
Gets merging compaction information.
Determines whether or not a merging compaction is needed, and if so, whether or not the "merge run" includes the end cell store (the one containing the most recent data) and therefore the cell cache can be included in the merging compaction.
- Parameters
-
needs_merging | Set to true if merge is needed |
end_merge | Set to true if merge run includes end cell store |
Definition at line 258 of file AccessGroup.h.
const char* Hypertable::AccessGroup::get_name |
( |
| ) |
|
|
inline |
bool AccessGroup::include_in_scan |
( |
ScanContext * |
scan_ctx | ) |
|
void AccessGroup::load_cellstore |
( |
CellStorePtr & |
cellstore | ) |
|
void AccessGroup::load_hints |
( |
Hints * |
hints | ) |
|
void Hypertable::AccessGroup::lock |
( |
| ) |
|
|
inline |
void AccessGroup::measure_garbage |
( |
double * |
total, |
|
|
double * |
garbage |
|
) |
| |
uint64_t AccessGroup::memory_usage |
( |
| ) |
|
void AccessGroup::merge_caches |
( |
| ) |
|
|
private |
void Hypertable::AccessGroup::post_load_cellstores |
( |
| ) |
|
|
inline |
void Hypertable::AccessGroup::pre_load_cellstores |
( |
| ) |
|
|
inline |
void AccessGroup::purge_stored_cells_from_cache |
( |
| ) |
|
|
private |
void AccessGroup::range_dir_initialize |
( |
| ) |
|
|
private |
HT_INFOF("Just initialized %s[%s..%s](%s) (pid=%d) to ID %u", m_table_name.c_str(), m_start_row.c_str(), m_end_row.c_str(), m_name.c_str(), (int)getpid(), (unsigned)m_next_cs_id);
Definition at line 1061 of file AccessGroup.cc.
void AccessGroup::recompute_compression_ratio |
( |
int64_t * |
total_index_entriesp = 0 | ) |
|
|
private |
void Hypertable::AccessGroup::recovery_finalize |
( |
| ) |
|
|
inline |
void Hypertable::AccessGroup::recovery_initialize |
( |
| ) |
|
|
inline |
void AccessGroup::release_files |
( |
const std::vector< String > & |
files | ) |
|
void AccessGroup::run_compaction |
( |
int |
maintenance_flags, |
|
|
Hints * |
hints |
|
) |
| |
Check for garbage and if threshold reached, change minor to major compaction. If GC compaction was requested and garbage threshold is not reached, skip compaction.
Install new CellCache and CellStore and update Live file tracker
Drop the compacted CellStores from the stores vector
Add the new cell store to the table vector, or delete it if it contains no entries
Definition at line 487 of file AccessGroup.cc.
void Hypertable::AccessGroup::set_next_csid |
( |
uint32_t |
nid | ) |
|
|
inline |
void AccessGroup::shrink |
( |
String & |
split_row, |
|
|
bool |
drop_high, |
|
|
Hints * |
hints |
|
) |
| |
void AccessGroup::sort_cellstores_by_timestamp |
( |
| ) |
|
|
private |
void AccessGroup::space_usage |
( |
int64_t * |
memp, |
|
|
int64_t * |
diskp |
|
) |
| |
void AccessGroup::stage_compaction |
( |
| ) |
|
void Hypertable::AccessGroup::unlock |
( |
| ) |
|
|
inline |
void AccessGroup::unstage_compaction |
( |
| ) |
|
Currently supports only adding and deleting column families from AccessGroup.
Changing other attributes of existing AccessGroup is not supported. Schema is only updated if the new schema has a more recent generation number than the existing schema.
Definition at line 98 of file AccessGroup.cc.
bool Hypertable::AccessGroup::m_cellcache_needs_compaction {} |
|
private |
std::set<uint8_t> Hypertable::AccessGroup::m_column_families |
|
private |
float Hypertable::AccessGroup::m_compression_ratio {1.0} |
|
private |
bool Hypertable::AccessGroup::m_dirty {} |
|
private |
uint64_t Hypertable::AccessGroup::m_disk_usage {} |
|
private |
int64_t Hypertable::AccessGroup::m_earliest_cached_revision {TIMESTAMP_MAX} |
|
private |
int64_t Hypertable::AccessGroup::m_earliest_cached_revision_saved {TIMESTAMP_MAX} |
|
private |
bool Hypertable::AccessGroup::m_end_merge {} |
|
private |
String Hypertable::AccessGroup::m_end_row |
|
private |
String Hypertable::AccessGroup::m_full_name |
|
private |
bool Hypertable::AccessGroup::m_in_memory {} |
|
private |
bool Hypertable::AccessGroup::m_is_root {} |
|
private |
int64_t Hypertable::AccessGroup::m_latest_stored_revision {TIMESTAMP_MIN} |
|
private |
int64_t Hypertable::AccessGroup::m_latest_stored_revision_hint {TIMESTAMP_MIN} |
|
private |
std::mutex Hypertable::AccessGroup::m_mutex |
|
private |
String Hypertable::AccessGroup::m_name |
|
private |
bool Hypertable::AccessGroup::m_needs_merging {} |
|
private |
uint32_t Hypertable::AccessGroup::m_next_cs_id {} |
|
private |
std::condition_variable Hypertable::AccessGroup::m_outstanding_scanner_cond |
|
private |
int32_t Hypertable::AccessGroup::m_outstanding_scanner_count |
|
private |
std::mutex Hypertable::AccessGroup::m_outstanding_scanner_mutex |
|
private |
String Hypertable::AccessGroup::m_range_dir |
|
private |
String Hypertable::AccessGroup::m_range_name |
|
private |
bool Hypertable::AccessGroup::m_recovering {} |
|
private |
std::mutex Hypertable::AccessGroup::m_schema_mutex |
|
private |
String Hypertable::AccessGroup::m_start_row |
|
private |
String Hypertable::AccessGroup::m_table_name |
|
private |
The documentation for this class was generated from the following files:
- /home/doug/src/hypertable/src/cc/Hypertable/RangeServer/AccessGroup.h
- /home/doug/src/hypertable/src/cc/Hypertable/RangeServer/AccessGroup.cc