Documentation ¶
Index ¶
- type FlumeClientPool
- func (self *FlumeClientPool) ActivePoolSize() int
- func (self *FlumeClientPool) Destroy()
- func (self *FlumeClientPool) Get(timeout time.Duration) (*client.FlumeClient, error)
- func (self *FlumeClientPool) GetHostPort() config.HostPort
- func (self *FlumeClientPool) MonitorPool() (int, int, int)
- func (self *FlumeClientPool) PoolSize() int
- func (self *FlumeClientPool) Release(fclient *client.FlumeClient) error
- func (self *FlumeClientPool) ReleaseBroken(fclient *client.FlumeClient) error
- type FlumePoolLink
- type IdleClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FlumeClientPool ¶
type FlumeClientPool struct {
// contains filtered or unexported fields
}
flume连接池
func (*FlumeClientPool) ActivePoolSize ¶
func (self *FlumeClientPool) ActivePoolSize() int
func (*FlumeClientPool) Destroy ¶
func (self *FlumeClientPool) Destroy()
func (*FlumeClientPool) Get ¶
func (self *FlumeClientPool) Get(timeout time.Duration) (*client.FlumeClient, error)
func (*FlumeClientPool) GetHostPort ¶
func (self *FlumeClientPool) GetHostPort() config.HostPort
func (*FlumeClientPool) MonitorPool ¶
func (self *FlumeClientPool) MonitorPool() (int, int, int)
func (*FlumeClientPool) Release ¶
func (self *FlumeClientPool) Release(fclient *client.FlumeClient) error
* * 归还当前的连接 *
func (*FlumeClientPool) ReleaseBroken ¶
func (self *FlumeClientPool) ReleaseBroken(fclient *client.FlumeClient) error
释放坏的资源
type FlumePoolLink ¶
type FlumePoolLink struct { FlumePool *FlumeClientPool BusinessLink *list.List //使用这个clientpool的业务名称 Mutex sync.RWMutex //保证在并发情况下能够对list的操作安全 }
flumeclient的pool Link
func NewFlumePoolLink ¶
func NewFlumePoolLink(hp config.HostPort) (error, *FlumePoolLink)
func (*FlumePoolLink) AttachBusiness ¶
func (self *FlumePoolLink) AttachBusiness(business string)
将该business从link加入
func (*FlumePoolLink) DetachBusiness ¶
func (self *FlumePoolLink) DetachBusiness(business string)
将该business从link重移除
func (*FlumePoolLink) IsAttached ¶
func (self *FlumePoolLink) IsAttached(business string) bool
type IdleClient ¶
type IdleClient struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.