Documentation ¶
Index ¶
- func EncodeToString(b []byte) string
- type Connection
- type ConnectionCache
- type ConnectionPool
- func (cp *ConnectionPool) Close(conn *Connection)
- func (cp *ConnectionPool) CloseAll()
- func (cp *ConnectionPool) Get() *Connection
- func (cp *ConnectionPool) GetWithRetry(count int) *Connection
- func (cp *ConnectionPool) NewConnection(address string) *Connection
- func (cp *ConnectionPool) Put(conn *Connection)
- func (cp *ConnectionPool) PutIfHealthy(conn *Connection)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EncodeToString ¶ added in v0.0.46
BytesToString Alternative to hex.EncodeToString(b)
Types ¶
type Connection ¶
type Connection struct { Address string Conn *grpc.ClientConn Counter int64 }
func (*Connection) Close ¶
func (c *Connection) Close()
type ConnectionCache ¶
type ConnectionCache struct {
Provider goburrow.LoadingCache
}
func NewConnectionCache ¶
func NewConnectionCache() *ConnectionCache
func (*ConnectionCache) Close ¶ added in v0.0.49
func (cc *ConnectionCache) Close(c *Connection)
func (*ConnectionCache) Get ¶
func (cc *ConnectionCache) Get(address string) *Connection
func (*ConnectionCache) Put ¶
func (cc *ConnectionCache) Put(c *Connection)
type ConnectionPool ¶
func (*ConnectionPool) Close ¶ added in v0.0.49
func (cp *ConnectionPool) Close(conn *Connection)
func (*ConnectionPool) CloseAll ¶ added in v0.0.79
func (cp *ConnectionPool) CloseAll()
func (*ConnectionPool) Get ¶
func (cp *ConnectionPool) Get() *Connection
func (*ConnectionPool) GetWithRetry ¶
func (cp *ConnectionPool) GetWithRetry(count int) *Connection
func (*ConnectionPool) NewConnection ¶ added in v0.0.79
func (cp *ConnectionPool) NewConnection(address string) *Connection
func (*ConnectionPool) Put ¶
func (cp *ConnectionPool) Put(conn *Connection)
func (*ConnectionPool) PutIfHealthy ¶
func (cp *ConnectionPool) PutIfHealthy(conn *Connection)
Click to show internal directories.
Click to hide internal directories.