22 #ifndef HYPERTABLE_RANGESERVERCONNECTION_H
23 #define HYPERTABLE_RANGESERVERCONNECTION_H
33 namespace RangeServerConnectionFlags {
41 class RangeServerHyperspaceCallback;
77 const std::string
to_str();
79 const String name()
override {
return "RangeServerConnection"; }
80 void display(std::ostream &os)
override;
88 void decode(
const uint8_t **bufp,
size_t *remainp,
89 uint16_t definition_version)
override;
100 size_t *remainp)
override;
102 void decode_old(
const uint8_t **bufp,
size_t *remainp);
120 #endif // HYPERTABLE_RANGESERVERCONNECTION_H
InetAddr public_addr() const
void decode(const uint8_t **bufp, size_t *remainp, uint16_t definition_version) override
Decodes serialized RangeServerConnection object.
std::shared_ptr< RangeServerConnection > RangeServerConnectionPtr
std::string String
A String is simply a typedef to std::string.
CommAddress get_comm_address()
size_t encoded_length_internal() const override
Returns internal serialized length.
InetAddr local_addr() const
Declarations for CommAddress.
void decode_old(const uint8_t **bufp, size_t *remainp)
Callback class for range server lock files.
double get_disk_fill_percentage()
RangeServerHyperspaceCallback * m_hyperspace_callback
Encapsulate an internet address.
double m_disk_fill_percentage
void set_hyperspace_handle(uint64_t handle, RangeServerHyperspaceCallback *cb)
void set_disk_fill_percentage(double percentage)
virtual ~RangeServerConnection()
void display(std::ostream &os) override
Prints a textual representation of the entity state to an ostream.
const String & hostname() const
const String & location() const
void decode_internal(uint8_t version, const uint8_t **bufp, size_t *remainp) override
Reads serialized representation of object from a buffer.
void encode_internal(uint8_t **bufp) const override
Writes serialized representation of object to a buffer.
uint8_t encoding_version() const override
Returns encoding version.
Internet address wrapper classes and utility functions.
bool connect(const String &hostname, InetAddr local_addr, InetAddr public_addr)
const std::string to_str()
const String name() override
Returns the name of the entity.
bool get_hyperspace_handle(uint64_t *handle, RangeServerHyperspaceCallback **cb)
RangeServerConnection(const String &location, const String &hostname, InetAddr public_addr)
Address abstraction to hold either proxy name or IPv4:port address.
void set_recovering(bool b)