Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrMaxConn = fmt.Errorf("maximum connections reached")
Functions ¶
This section is empty.
Types ¶
type ConnPool ¶
type ConnPool struct { sync.RWMutex Name string Address string MaxConn int32 MaxIdle int32 Cnt int64 New func(name string) (NConn, error) // contains filtered or unexported fields }
conn pool
func NewConnPool ¶
func (*ConnPool) ForceClose ¶
type RpcClient ¶
type RpcClient struct {
// contains filtered or unexported fields
}
func NewRpcClientWithCodec ¶
func NewRpcClientWithCodec(codec rpc.ClientCodec, name string) *RpcClient
type RpcConnPools ¶
type RpcConnPools struct { sync.RWMutex M map[string]*ConnPool MaxConn int MaxIdle int ConnTimeout int CallTimeout int }
func CreateRpcConnPools ¶
func CreateRpcConnPools(maxConn, maxIdle, connTimeout, callTimeout int, cluster []string) *RpcConnPools
func (*RpcConnPools) Call ¶
func (u *RpcConnPools) Call(addr, method string, args interface{}, resp interface{}) error
func (*RpcConnPools) Destroy ¶
func (u *RpcConnPools) Destroy()
func (*RpcConnPools) Proc ¶
func (u *RpcConnPools) Proc() []string
type TsDBClient ¶
type TsDBClient struct {
// contains filtered or unexported fields
}
func (TsDBClient) Close ¶
func (u TsDBClient) Close() error
func (TsDBClient) Closed ¶
func (u TsDBClient) Closed() bool
func (TsDBClient) Name ¶
func (u TsDBClient) Name() string
type TsDBConnPools ¶
type TsDBConnPools struct {
// contains filtered or unexported fields
}
func NewTsDBConnPool ¶
func NewTsDBConnPool(address string, maxConn, maxIdle, connTimeout, callTimeout int) *TsDBConnPools
func (*TsDBConnPools) Destroy ¶
func (t *TsDBConnPools) Destroy()
func (*TsDBConnPools) Send ¶
func (t *TsDBConnPools) Send(data []byte) error
Click to show internal directories.
Click to hide internal directories.