Documentation
¶
Index ¶
Constants ¶
View Source
const ( // RegionClient is a ClientType that means this will be a normal client RegionClient = ClientType("ClientService") // MasterClient is a ClientType that means this client will talk to the // master server MasterClient = ClientType("MasterService") )
Variables ¶
View Source
var ( // ErrShortWrite is used when the writer thread only succeeds in writing // part of its buffer to the socket, and not all of the buffer was sent ErrShortWrite = errors.New("short write occurred while writing to socket") // ErrMissingCallID is used when HBase sends us a response message for a // request that we didn't send ErrMissingCallID = errors.New("HBase responded to a nonsensical call ID") )
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client manages a connection to a RegionServer.
func NewClient ¶
func NewClient(host string, port uint16, ctype ClientType, queueSize int, flushInterval time.Duration) (*Client, error)
NewClient creates a new RegionClient.
func (*Client) Close ¶
func (c *Client) Close()
Close asks this region.Client to close its connection to the RegionServer. All queued and outstanding RPCs, if any, will be failed as if a connection error had happened.
type ClientType ¶
type ClientType string
ClientType is a type alias to represent the type of this region client
type RetryableError ¶
type RetryableError struct {
// contains filtered or unexported fields
}
RetryableError is an error that indicates the RPC should be retried because the error is transient (e.g. a region being momentarily unavailable).
func (RetryableError) Error ¶
func (e RetryableError) Error() string
type UnrecoverableError ¶
type UnrecoverableError struct {
// contains filtered or unexported fields
}
UnrecoverableError is an error that this region.Client can't recover from. The connection to the RegionServer has to be closed and all queued and outstanding RPCs will be failed / retried.
func (UnrecoverableError) Error ¶
func (e UnrecoverableError) Error() string
Click to show internal directories.
Click to hide internal directories.