Client interface to RangeServer. More...
#include <Client.h>
Public Member Functions | |
Client (Comm *comm, int32_t timeout_ms=0) | |
~Client () | |
void | set_default_timeout (int32_t timeout_ms) |
Sets the default client connection timeout. More... | |
int32_t | default_timeout () const |
void | compact (const CommAddress &addr, const TableIdentifier &table, const String &row, int32_t flags) |
Issues a "compact" request synchronously. More... | |
void | compact (const CommAddress &addr, const TableIdentifier &table, const String &row, int32_t flags, DispatchHandler *handler) |
Issues a "compact" request asynchronously. More... | |
void | compact (const CommAddress &addr, const TableIdentifier &table, const String &row, int32_t flags, DispatchHandler *handler, Timer &timer) |
Issues a "compact" request asynchronously with a timer. More... | |
void | load_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range_spec, const RangeState &range_state, bool needs_compaction) |
Issues a synchronous "load range" request. More... | |
void | load_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range_spec, const RangeState &range_state, bool needs_compaction, Timer &timer) |
Issues a synchronous "load range" request with timer. More... | |
void | acknowledge_load (const CommAddress &addr, const vector< QualifiedRangeSpec * > &ranges, std::map< QualifiedRangeSpec, int > &response_map) |
Issues a synchronous "acknowledge load" request for multiple ranges. More... | |
void | update (const CommAddress &addr, uint64_t cluster_id, const TableIdentifier &table, int32_t count, StaticBuffer &buffer, int32_t flags, DispatchHandler *handler) |
Issues an "update" request asynchronously. More... | |
void | create_scanner (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, const ScanSpec &scan_spec, DispatchHandler *handler) |
Issues a "create scanner" request asynchronously. More... | |
void | create_scanner (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, const ScanSpec &scan_spec, DispatchHandler *handler, Timer &timer) |
Issues a "create scanner" request asynchronously with timer. More... | |
void | create_scanner (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, const ScanSpec &scan_spec, ScanBlock &scan_block) |
Issues a "create scanner" request. More... | |
void | create_scanner (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, const ScanSpec &scan_spec, ScanBlock &scan_block, Timer &timer) |
Issues a synchronous "create scanner" request with timer. More... | |
void | destroy_scanner (const CommAddress &addr, int32_t scanner_id, DispatchHandler *handler) |
Issues a "destroy scanner" request asynchronously. More... | |
void | destroy_scanner (const CommAddress &addr, int32_t scanner_id, DispatchHandler *handler, Timer &timer) |
Issues a "destroy scanner" request asynchronously with timer. More... | |
void | destroy_scanner (const CommAddress &addr, int32_t scanner_id) |
Issues a synchronous "destroy scanner" request. More... | |
void | destroy_scanner (const CommAddress &addr, int32_t scanner_id, Timer &timer) |
Issues a synchronous "destroy scanner" request with timer. More... | |
void | fetch_scanblock (const CommAddress &addr, int32_t scanner_id, DispatchHandler *handler) |
Issues a "fetch scanblock" request asynchronously. More... | |
void | fetch_scanblock (const CommAddress &addr, int32_t scanner_id, DispatchHandler *handler, Timer &timer) |
Issues a "fetch scanblock" request asynchronously. More... | |
void | fetch_scanblock (const CommAddress &addr, int32_t scanner_id, ScanBlock &scan_block) |
Issues a synchronous "fetch scanblock" request. More... | |
void | fetch_scanblock (const CommAddress &addr, int32_t scanner_id, ScanBlock &scan_block, Timer &timer) |
Issues a synchronous "fetch scanblock" request with timer. More... | |
void | drop_table (const CommAddress &addr, const TableIdentifier &table, DispatchHandler *handler) |
Issues a "drop table" request asynchronously. More... | |
void | drop_table (const CommAddress &addr, const TableIdentifier &table, DispatchHandler *handler, Timer &timer) |
Issues a "drop table" request asynchronously with timer. More... | |
void | drop_table (const CommAddress &addr, const TableIdentifier &table) |
Issues a synchronous "drop table" request. More... | |
void | drop_table (const CommAddress &addr, const TableIdentifier &table, Timer &timer) |
Issues a synchronous "drop table" request with timer. More... | |
void | update_schema (const CommAddress &addr, const TableIdentifier &table, const String &schema, DispatchHandler *handler) |
Issues a "update schema" request asynchronously. More... | |
void | update_schema (const CommAddress &addr, const TableIdentifier &table, const String &schema, DispatchHandler *handler, Timer &timer) |
Issues a "update schema" request asynchronously with timer. More... | |
void | commit_log_sync (const CommAddress &addr, uint64_t cluster_id, const TableIdentifier &table, DispatchHandler *handler) |
Issues a "commit_log_sync" request asynchronously. More... | |
void | commit_log_sync (const CommAddress &addr, uint64_t cluster_id, const TableIdentifier &table, DispatchHandler *handler, Timer &timer) |
Issues a "commit_log_sync" request asynchronously with timer. More... | |
void | status (const CommAddress &addr, Status &status) |
Issues a "status" request. More... | |
void | status (const CommAddress &addr, Status &status, Timer &timer) |
Issues a "status" request with timer. More... | |
void | status (const CommAddress &addr, DispatchHandler *handler, Timer &timer) |
Issues an asynchonous status request with timer. More... | |
void | wait_for_maintenance (const CommAddress &addr) |
Issues a "wait_for_maintenance" request. More... | |
void | shutdown (const CommAddress &addr) |
Issues a "shutdown" request. More... | |
void | dump (const CommAddress &addr, String &outfile, bool nokeys) |
void | dump_pseudo_table (const CommAddress &addr, const TableIdentifier &table, const String &pseudo_table_name, const String &outfile) |
void | get_statistics (const CommAddress &addr, std::vector< SystemVariable::Spec > &specs, int64_t generation, StatsRangeServer &stats) |
Issues an synchronous "get_statistics" request. More... | |
void | get_statistics (const CommAddress &addr, std::vector< SystemVariable::Spec > &specs, int64_t generation, StatsRangeServer &stats, Timer &timer) |
Issues an synchronous "get_statistics" request with timer. More... | |
void | get_statistics (const CommAddress &addr, std::vector< SystemVariable::Spec > &specs, int64_t generation, DispatchHandler *handler) |
Issues an asynchronous "get_statistics" request. More... | |
void | get_statistics (const CommAddress &addr, std::vector< SystemVariable::Spec > &specs, int64_t generation, DispatchHandler *handler, Timer &timer) |
Issues an asynchronous "get_statistics" request with timer. More... | |
void | drop_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, DispatchHandler *handler) |
Issues an asynchronous "drop range" request asynchronously. More... | |
void | drop_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, DispatchHandler *handler, Timer &timer) |
Issues an asynchronous "drop range" request asynchronously with timer. More... | |
void | relinquish_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range) |
Issues a "relinquish range" request synchronously. More... | |
void | relinquish_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, Timer &timer) |
Issues a "relinquish range" request synchronously, with timer. More... | |
void | heapcheck (const CommAddress &addr, String &outfile) |
Issues a "heapcheck" request. More... | |
void | replay_fragments (const CommAddress &addr, int64_t op_id, const String &recover_location, int32_t plan_generation, int32_t type, const vector< int32_t > &fragments, const Lib::RangeServerRecovery::ReceiverPlan &plan, int32_t replay_timeout) |
Issues a synchronous "replay_fragments" request. More... | |
void | phantom_load (const CommAddress &addr, const String &location, int32_t plan_generation, const vector< int32_t > &fragments, const vector< QualifiedRangeSpec > &range_specs, const vector< RangeState > &range_states) |
Issues a "phantom_load" synchronous request. More... | |
void | phantom_update (const CommAddress &addr, const String &location, int32_t plan_generation, const QualifiedRangeSpec &range, int32_t fragment, StaticBuffer &updates, DispatchHandler *handler) |
Issues a "phantom_update" asynchronous request. More... | |
void | phantom_prepare_ranges (const CommAddress &addr, int64_t op_id, const String &location, int32_t plan_generation, const vector< QualifiedRangeSpec > &ranges, int32_t timeout) |
Issues a "phantom_prepare_ranges" synchronous request. More... | |
void | phantom_commit_ranges (const CommAddress &addr, int64_t op_id, const String &location, int32_t plan_generation, const vector< QualifiedRangeSpec > &ranges, int32_t timeout) |
Issues a "phantom_commit_ranges" synchronous request. More... | |
void | set_state (const CommAddress &addr, std::vector< SystemVariable::Spec > &specs, int64_t generation, DispatchHandler *handler, Timer &timer) |
Issues an asynchronous "set_state" request with timer. More... | |
void | table_maintenance_enable (const CommAddress &addr, const TableIdentifier &table, DispatchHandler *handler) |
Issues an asynchronous RangeServer::table_maintenance_enable(). More... | |
void | table_maintenance_disable (const CommAddress &addr, const TableIdentifier &table, DispatchHandler *handler) |
Issues an asynchronous RangeServer::table_maintenance_disable() request. More... | |
Private Member Functions | |
void | do_load_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range_spec, const RangeState &range_state, bool needs_compaction, int32_t timeout_ms) |
void | do_create_scanner (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, const ScanSpec &scan_spec, ScanBlock &scan_block, int32_t timeout_ms) |
void | do_destroy_scanner (const CommAddress &addr, int32_t scanner_id, int32_t timeout_ms) |
void | do_fetch_scanblock (const CommAddress &addr, int32_t scanner_id, ScanBlock &scan_block, int32_t timeout_ms) |
void | do_drop_table (const CommAddress &addr, const TableIdentifier &table, int32_t timeout_ms) |
void | do_status (const CommAddress &addr, Status &status, int32_t timeout_ms) |
void | do_get_statistics (const CommAddress &addr, std::vector< SystemVariable::Spec > &specs, int64_t generation, StatsRangeServer &stats, int32_t timeout_ms) |
void | do_relinquish_range (const CommAddress &addr, const TableIdentifier &table, const RangeSpec &range, int32_t timeout_ms) |
void | send_message (const CommAddress &addr, CommBufPtr &cbp, DispatchHandler *handler, int32_t timeout_ms) |
Private Attributes | |
Comm * | m_comm |
int32_t | m_default_timeout_ms |
Client interface to RangeServer.
This class provides a client interface to the RangeServer. It has methods, both synchronous and asynchronous, that carry out RangeServer operations.
Lib::RangeServer::Client::Client | ( | Comm * | comm, |
int32_t | timeout_ms = 0 |
||
) |
void Lib::RangeServer::Client::acknowledge_load | ( | const CommAddress & | addr, |
const vector< QualifiedRangeSpec * > & | ranges, | ||
std::map< QualifiedRangeSpec, int > & | response_map | ||
) |
Issues a synchronous "acknowledge load" request for multiple ranges.
addr | address of RangeServer |
ranges | qualified range spec |
response_map | per range responses to acknowledge_load |
void Lib::RangeServer::Client::commit_log_sync | ( | const CommAddress & | addr, |
uint64_t | cluster_id, | ||
const TableIdentifier & | table, | ||
DispatchHandler * | handler | ||
) |
Issues a "commit_log_sync" request asynchronously.
addr | address of RangeServer |
cluster_id | Originating cluster ID |
table | Table for which commit log sync is needed |
handler | response handler |
void Lib::RangeServer::Client::commit_log_sync | ( | const CommAddress & | addr, |
uint64_t | cluster_id, | ||
const TableIdentifier & | table, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues a "commit_log_sync" request asynchronously with timer.
addr | address of RangeServer |
cluster_id | Originating cluster ID |
table | Table for which commit log sync is needed |
handler | response handler |
timer | timer |
void Lib::RangeServer::Client::compact | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const String & | row, | ||
int32_t | flags | ||
) |
Issues a "compact" request synchronously.
addr | address of RangeServer |
table | Table identifier of table to compact |
row | Row containing range to compact |
flags | Compaction flags (see RangeServerProtocol::CompactionFlags) |
void Lib::RangeServer::Client::compact | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const String & | row, | ||
int32_t | flags, | ||
DispatchHandler * | handler | ||
) |
Issues a "compact" request asynchronously.
addr | address of RangeServer |
table | Table identifier of table to compact |
row | Row containing range to compact |
flags | Compaction flags (see RangeServerProtocol::CompactionFlags) |
handler | Dispatch handler |
void Lib::RangeServer::Client::compact | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const String & | row, | ||
int32_t | flags, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues a "compact" request asynchronously with a timer.
addr | address of RangeServer |
table | Table identifier of table to compact |
row | Row containing range to compact |
flags | Compaction flags (see RangeServerProtocol::CompactionFlags) |
handler | dispatch handler |
timer | Deadline timer |
void Lib::RangeServer::Client::create_scanner | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range, | ||
const ScanSpec & | scan_spec, | ||
DispatchHandler * | handler | ||
) |
Issues a "create scanner" request asynchronously.
addr | address of RangeServer |
table | table identifier |
range | range specification |
scan_spec | scan specification |
handler | response handler |
void Lib::RangeServer::Client::create_scanner | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range, | ||
const ScanSpec & | scan_spec, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues a "create scanner" request asynchronously with timer.
addr | address of RangeServer |
table | table identifier |
range | range specification |
scan_spec | scan specification |
handler | response handler |
timer | timer |
void Lib::RangeServer::Client::create_scanner | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range, | ||
const ScanSpec & | scan_spec, | ||
ScanBlock & | scan_block | ||
) |
Issues a "create scanner" request.
addr | address of RangeServer |
table | table identifier |
range | range specification |
scan_spec | scan specification |
scan_block | block of return key/value pairs |
void Lib::RangeServer::Client::create_scanner | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range, | ||
const ScanSpec & | scan_spec, | ||
ScanBlock & | scan_block, | ||
Timer & | timer | ||
) |
Issues a synchronous "create scanner" request with timer.
addr | address of RangeServer |
table | table identifier |
range | range specification |
scan_spec | scan specification |
scan_block | block of return key/value pairs |
timer | timer |
|
inline |
void Lib::RangeServer::Client::destroy_scanner | ( | const CommAddress & | addr, |
int32_t | scanner_id, | ||
DispatchHandler * | handler | ||
) |
Issues a "destroy scanner" request asynchronously.
addr | address of RangeServer |
scanner_id | Scanner ID returned from a call to create_scanner. |
handler | response handler |
void Lib::RangeServer::Client::destroy_scanner | ( | const CommAddress & | addr, |
int32_t | scanner_id, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues a "destroy scanner" request asynchronously with timer.
addr | address of RangeServer |
scanner_id | Scanner ID returned from a call to create_scanner. |
handler | response handler |
timer | timer |
void Lib::RangeServer::Client::destroy_scanner | ( | const CommAddress & | addr, |
int32_t | scanner_id | ||
) |
Issues a synchronous "destroy scanner" request.
addr | address of RangeServer |
scanner_id | scanner ID returned from a call to create_scanner. |
void Lib::RangeServer::Client::destroy_scanner | ( | const CommAddress & | addr, |
int32_t | scanner_id, | ||
Timer & | timer | ||
) |
Issues a synchronous "destroy scanner" request with timer.
addr | address of RangeServer |
scanner_id | scanner ID returned from a call to create_scanner. |
timer | timer |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
void Lib::RangeServer::Client::drop_range | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range, | ||
DispatchHandler * | handler | ||
) |
Issues an asynchronous "drop range" request asynchronously.
addr | address of RangeServer |
table | table identifier |
range | range specification |
handler | response handler |
void Lib::RangeServer::Client::drop_range | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues an asynchronous "drop range" request asynchronously with timer.
addr | address of RangeServer |
table | table identifier |
range | range specification |
handler | response handler |
timer | timer |
void Lib::RangeServer::Client::drop_table | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
DispatchHandler * | handler | ||
) |
Issues a "drop table" request asynchronously.
addr | address of RangeServer |
table | table identifier |
handler | response handler |
void Lib::RangeServer::Client::drop_table | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues a "drop table" request asynchronously with timer.
addr | address of RangeServer |
table | table identifier |
handler | response handler |
timer | timer |
void Lib::RangeServer::Client::drop_table | ( | const CommAddress & | addr, |
const TableIdentifier & | table | ||
) |
Issues a synchronous "drop table" request.
addr | address of RangeServer |
table | table identifier |
void Hypertable::Lib::RangeServer::Client::drop_table | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
Timer & | timer | ||
) |
Issues a synchronous "drop table" request with timer.
addr | address of RangeServer |
table | table identifier |
timer | timer |
void Lib::RangeServer::Client::dump | ( | const CommAddress & | addr, |
String & | outfile, | ||
bool | nokeys | ||
) |
void Lib::RangeServer::Client::dump_pseudo_table | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const String & | pseudo_table_name, | ||
const String & | outfile | ||
) |
void Lib::RangeServer::Client::fetch_scanblock | ( | const CommAddress & | addr, |
int32_t | scanner_id, | ||
DispatchHandler * | handler | ||
) |
Issues a "fetch scanblock" request asynchronously.
addr | address of RangeServer |
scanner_id | Scanner ID returned from a call to create_scanner. |
handler | response handler |
void Lib::RangeServer::Client::fetch_scanblock | ( | const CommAddress & | addr, |
int32_t | scanner_id, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues a "fetch scanblock" request asynchronously.
addr | address of RangeServer |
scanner_id | Scanner ID returned from a call to create_scanner. |
handler | response handler |
timer | timer |
void Lib::RangeServer::Client::fetch_scanblock | ( | const CommAddress & | addr, |
int32_t | scanner_id, | ||
ScanBlock & | scan_block | ||
) |
Issues a synchronous "fetch scanblock" request.
addr | address of RangeServer |
scanner_id | scanner ID returned from a call to create_scanner. |
scan_block | block of return key/value pairs |
void Lib::RangeServer::Client::fetch_scanblock | ( | const CommAddress & | addr, |
int32_t | scanner_id, | ||
ScanBlock & | scan_block, | ||
Timer & | timer | ||
) |
Issues a synchronous "fetch scanblock" request with timer.
addr | address of RangeServer |
scanner_id | scanner ID returned from a call to create_scanner. |
scan_block | block of return key/value pairs |
timer | timer |
void Lib::RangeServer::Client::get_statistics | ( | const CommAddress & | addr, |
std::vector< SystemVariable::Spec > & | specs, | ||
int64_t | generation, | ||
StatsRangeServer & | stats | ||
) |
Issues an synchronous "get_statistics" request.
addr | address of RangeServer |
specs | Vector of system state variable specs |
generation | System state generation |
stats | reference to RangeServer stats object |
void Lib::RangeServer::Client::get_statistics | ( | const CommAddress & | addr, |
std::vector< SystemVariable::Spec > & | specs, | ||
int64_t | generation, | ||
StatsRangeServer & | stats, | ||
Timer & | timer | ||
) |
Issues an synchronous "get_statistics" request with timer.
addr | address of RangeServer |
specs | Vector of system state variable specs |
generation | System state generation |
stats | reference to RangeServer stats object |
timer | timer |
void Lib::RangeServer::Client::get_statistics | ( | const CommAddress & | addr, |
std::vector< SystemVariable::Spec > & | specs, | ||
int64_t | generation, | ||
DispatchHandler * | handler | ||
) |
Issues an asynchronous "get_statistics" request.
addr | address of RangeServer |
specs | Vector of system state variable specs |
generation | System state generation |
handler | Dispatch handler for asynchronous callback |
void Lib::RangeServer::Client::get_statistics | ( | const CommAddress & | addr, |
std::vector< SystemVariable::Spec > & | specs, | ||
int64_t | generation, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues an asynchronous "get_statistics" request with timer.
addr | Address of RangeServer |
specs | Vector of system state variable specs |
generation | System state generation |
handler | Dispatch handler for asynchronous callback |
timer | Maximum wait timer |
void Lib::RangeServer::Client::heapcheck | ( | const CommAddress & | addr, |
String & | outfile | ||
) |
Issues a "heapcheck" request.
This call blocks until it receives a response from the server.
addr | address of RangeServer |
outfile | output file to dump heap stats to |
void Lib::RangeServer::Client::load_range | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range_spec, | ||
const RangeState & | range_state, | ||
bool | needs_compaction | ||
) |
Issues a synchronous "load range" request.
addr | address of RangeServer |
table | table identifier |
range_spec | range specification |
range_state | range state |
needs_compaction | if true range needs compaction after load |
void Lib::RangeServer::Client::load_range | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range_spec, | ||
const RangeState & | range_state, | ||
bool | needs_compaction, | ||
Timer & | timer | ||
) |
Issues a synchronous "load range" request with timer.
addr | address of RangeServer |
table | table identifier |
range_spec | range specification |
range_state | range state |
needs_compaction | if true range needs compaction after load |
timer | timer |
void Lib::RangeServer::Client::phantom_commit_ranges | ( | const CommAddress & | addr, |
int64_t | op_id, | ||
const String & | location, | ||
int32_t | plan_generation, | ||
const vector< QualifiedRangeSpec > & | ranges, | ||
int32_t | timeout | ||
) |
Issues a "phantom_commit_ranges" synchronous request.
addr | address of RangeServer |
op_id | ID of Master recovery operation |
location | location of server being recovered |
plan_generation | recovery plan generation |
ranges | range specs to be committed |
timeout | timeout |
void Lib::RangeServer::Client::phantom_load | ( | const CommAddress & | addr, |
const String & | location, | ||
int32_t | plan_generation, | ||
const vector< int32_t > & | fragments, | ||
const vector< QualifiedRangeSpec > & | range_specs, | ||
const vector< RangeState > & | range_states | ||
) |
Issues a "phantom_load" synchronous request.
addr | address of RangeServer |
location | location of server being recovered |
plan_generation | recovery plan generation |
fragments | fragments being replayed |
range_specs | range specs to be loaded |
range_states | parallel range states array |
void Lib::RangeServer::Client::phantom_prepare_ranges | ( | const CommAddress & | addr, |
int64_t | op_id, | ||
const String & | location, | ||
int32_t | plan_generation, | ||
const vector< QualifiedRangeSpec > & | ranges, | ||
int32_t | timeout | ||
) |
Issues a "phantom_prepare_ranges" synchronous request.
addr | address of RangeServer |
op_id | ID of Master recovery operation |
location | location of server being recovered |
plan_generation | recovery plan generation |
ranges | range specs to be prepared |
timeout | timeout |
void Lib::RangeServer::Client::phantom_update | ( | const CommAddress & | addr, |
const String & | location, | ||
int32_t | plan_generation, | ||
const QualifiedRangeSpec & | range, | ||
int32_t | fragment, | ||
StaticBuffer & | updates, | ||
DispatchHandler * | handler | ||
) |
Issues a "phantom_update" asynchronous request.
addr | address of RangeServer |
location | location being recovered |
plan_generation | recovery plan generation |
range | Qualfied range specification |
fragment | Fragment ID |
updates | Buffer of updates |
handler | Dispatch handler |
void Lib::RangeServer::Client::relinquish_range | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range | ||
) |
Issues a "relinquish range" request synchronously.
addr | address of RangeServer |
table | table identifier |
range | range specification |
void Lib::RangeServer::Client::relinquish_range | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const RangeSpec & | range, | ||
Timer & | timer | ||
) |
Issues a "relinquish range" request synchronously, with timer.
addr | address of RangeServer |
table | table identifier |
range | range specification |
timer | timer |
void Lib::RangeServer::Client::replay_fragments | ( | const CommAddress & | addr, |
int64_t | op_id, | ||
const String & | recover_location, | ||
int32_t | plan_generation, | ||
int32_t | type, | ||
const vector< int32_t > & | fragments, | ||
const Lib::RangeServerRecovery::ReceiverPlan & | plan, | ||
int32_t | replay_timeout | ||
) |
Issues a synchronous "replay_fragments" request.
addr | Address of RangeServer |
op_id | ID of the calling recovery operation |
recover_location | Location of the server being recovered |
plan_generation | Recovery plan generation |
type | Type of fragments to play |
fragments | Fragments being requested for replay |
plan | Recovery receiver plan |
replay_timeout | timeout for replay to finish |
|
private |
|
inline |
void Lib::RangeServer::Client::set_state | ( | const CommAddress & | addr, |
std::vector< SystemVariable::Spec > & | specs, | ||
int64_t | generation, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues an asynchronous "set_state" request with timer.
addr | Address of RangeServer |
specs | Vector of system state variable specs |
generation | System state generation |
handler | Dispatch handler for asynchronous callback |
timer | Maximum wait timer |
void Lib::RangeServer::Client::shutdown | ( | const CommAddress & | addr | ) |
Issues a "shutdown" request.
This call blocks until it receives a response from the server or times out.
addr | address of RangeServer |
void Lib::RangeServer::Client::status | ( | const CommAddress & | addr, |
Status & | status | ||
) |
Issues a "status" request.
This call blocks until it receives a response from the server.
addr | address of RangeServer |
status | Output variable to hold status |
void Lib::RangeServer::Client::status | ( | const CommAddress & | addr, |
Status & | status, | ||
Timer & | timer | ||
) |
Issues a "status" request with timer.
This call blocks until it receives a response from the server.
addr | address of RangeServer |
status | Output variable to hold status |
timer | timer |
void Lib::RangeServer::Client::status | ( | const CommAddress & | addr, |
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues an asynchonous status request with timer.
addr | Address of RangeServer |
handler | Response handler |
timer | Deadline timer |
void Lib::RangeServer::Client::table_maintenance_disable | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
DispatchHandler * | handler | ||
) |
Issues an asynchronous RangeServer::table_maintenance_disable() request.
addr | Address of RangeServer |
table | Table identifier |
handler | Dispatch handler for asynchronous callback |
void Lib::RangeServer::Client::table_maintenance_enable | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
DispatchHandler * | handler | ||
) |
Issues an asynchronous RangeServer::table_maintenance_enable().
addr | Address of RangeServer |
table | Table identifier |
handler | Dispatch handler for asynchronous callback |
void Lib::RangeServer::Client::update | ( | const CommAddress & | addr, |
uint64_t | cluster_id, | ||
const TableIdentifier & | table, | ||
int32_t | count, | ||
StaticBuffer & | buffer, | ||
int32_t | flags, | ||
DispatchHandler * | handler | ||
) |
Issues an "update" request asynchronously.
The data argument holds a sequence of key/value pairs. Each key/value pair is encoded as two variable lenght ByteString records back-to-back. This method takes ownership of the data buffer.
addr | address of RangeServer |
cluster_id | Originating cluster ID |
table | table identifier |
count | number of key/value pairs in buffer |
buffer | buffer holding key/value pairs |
flags | update flags |
handler | response handler |
void Lib::RangeServer::Client::update_schema | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const String & | schema, | ||
DispatchHandler * | handler | ||
) |
Issues a "update schema" request asynchronously.
addr | address of RangeServer |
table | table identifier |
schema | the new schema for this table |
handler | response handler |
void Lib::RangeServer::Client::update_schema | ( | const CommAddress & | addr, |
const TableIdentifier & | table, | ||
const String & | schema, | ||
DispatchHandler * | handler, | ||
Timer & | timer | ||
) |
Issues a "update schema" request asynchronously with timer.
addr | address of RangeServer |
table | table identifier |
schema | the new schema for this table |
handler | response handler |
timer | timer |
void Lib::RangeServer::Client::wait_for_maintenance | ( | const CommAddress & | addr | ) |
Issues a "wait_for_maintenance" request.
This call blocks until it receives a response from the server or times out.
addr | address of RangeServer |
|
private |