Documentation ¶
Index ¶
- func DateTimeString2(val time.Time) string
- type ByPassGroup
- func (this *ByPassGroup) BeginUpdate()
- func (this *ByPassGroup) ConfigStrategy(v int8)
- func (this *ByPassGroup) DeleteByPassItem(id string) (isChanged bool)
- func (this *ByPassGroup) EndUpdate(removeflag bool) (upcnt int)
- func (this *ByPassGroup) GetByPassNode() (node *ByPassItem)
- func (this *ByPassGroup) ReleaseByPassNode(node *ByPassItem, fail bool, block time.Duration, failmsg string)
- func (this *ByPassGroup) Status() string
- func (this *ByPassGroup) UpdateByPassNode(id string, sn int16, max int, data interface{}) (isChanged bool)
- type ByPassItem
- type ByPassMananger
- func (this *ByPassMananger) CheckGetByPassGroup(id string, newflag bool) *ByPassGroup
- func (this *ByPassMananger) GetByPassNode(groupid string) (rval *ByPassItem)
- func (this *ByPassMananger) GetStatusText(lvl int) string
- func (this *ByPassMananger) ReleaseByPassNode(itm *ByPassItem, fail bool, block time.Duration, failmsg string)
- func (this *ByPassMananger) TrySetDefault(id string) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DateTimeString2 ¶
Types ¶
type ByPassGroup ¶
type ByPassGroup struct {
// contains filtered or unexported fields
}
分流组管理,管理分流节点
func NewByPassGroup ¶
func NewByPassGroup() *ByPassGroup
func (*ByPassGroup) ConfigStrategy ¶
func (this *ByPassGroup) ConfigStrategy(v int8)
func (*ByPassGroup) DeleteByPassItem ¶
func (this *ByPassGroup) DeleteByPassItem(id string) (isChanged bool)
func (*ByPassGroup) EndUpdate ¶
func (this *ByPassGroup) EndUpdate(removeflag bool) (upcnt int)
removeflag true:清理没有更新过的 upcnt 本次更新数量
func (*ByPassGroup) GetByPassNode ¶
func (this *ByPassGroup) GetByPassNode() (node *ByPassItem)
获取分流节点
func (*ByPassGroup) ReleaseByPassNode ¶
func (this *ByPassGroup) ReleaseByPassNode(node *ByPassItem, fail bool, block time.Duration, failmsg string)
获取分流节点
func (*ByPassGroup) Status ¶
func (this *ByPassGroup) Status() string
func (*ByPassGroup) UpdateByPassNode ¶
func (this *ByPassGroup) UpdateByPassNode(id string, sn int16, max int, data interface{}) (isChanged bool)
type ByPassItem ¶
type ByPassItem struct { Tag interface{} // contains filtered or unexported fields }
func (*ByPassItem) GetData ¶
func (this *ByPassItem) GetData() interface{}
func (*ByPassItem) GetID ¶ added in v1.2.24051
func (this *ByPassItem) GetID() string
func (*ByPassItem) Lock ¶ added in v1.2.24051
func (this *ByPassItem) Lock()
func (*ByPassItem) RLock ¶ added in v1.2.24051
func (this *ByPassItem) RLock()
func (*ByPassItem) RUnlock ¶ added in v1.2.24051
func (this *ByPassItem) RUnlock()
func (*ByPassItem) Unlock ¶ added in v1.2.24051
func (this *ByPassItem) Unlock()
type ByPassMananger ¶
type ByPassMananger struct {
// contains filtered or unexported fields
}
func NewByPassManager ¶
func NewByPassManager() *ByPassMananger
func (*ByPassMananger) CheckGetByPassGroup ¶
func (this *ByPassMananger) CheckGetByPassGroup(id string, newflag bool) *ByPassGroup
func (*ByPassMananger) GetByPassNode ¶
func (this *ByPassMananger) GetByPassNode(groupid string) (rval *ByPassItem)
获取一个分流节点
func (*ByPassMananger) GetStatusText ¶
func (this *ByPassMananger) GetStatusText(lvl int) string
func (*ByPassMananger) ReleaseByPassNode ¶
func (this *ByPassMananger) ReleaseByPassNode(itm *ByPassItem, fail bool, block time.Duration, failmsg string)
释放一个分流节点
func (*ByPassMananger) TrySetDefault ¶
func (this *ByPassMananger) TrySetDefault(id string) bool
Click to show internal directories.
Click to hide internal directories.