Documentation ¶
Index ¶
- Constants
- type CollectionObserver
- func (ob *CollectionObserver) LoadCollection(ctx context.Context, collectionID int64)
- func (ob *CollectionObserver) LoadPartitions(ctx context.Context, collectionID int64, partitionIDs []int64)
- func (ob *CollectionObserver) Observe(ctx context.Context)
- func (ob *CollectionObserver) Start()
- func (ob *CollectionObserver) Stop()
- type CollectionShardLeaderCache
- type LeaderCacheObserver
- type LoadTask
- type ReplicaObserver
- type ResourceObserver
- type TargetObserver
- func (ob *TargetObserver) Check(ctx context.Context, collectionID int64, partitionID int64) bool
- func (ob *TargetObserver) ReleaseCollection(collectionID int64)
- func (ob *TargetObserver) ReleasePartition(collectionID int64, partitionID ...int64)
- func (ob *TargetObserver) Start()
- func (ob *TargetObserver) Stop()
- func (ob *TargetObserver) TriggerUpdateCurrentTarget(collectionID int64)
- func (ob *TargetObserver) UpdateNextTarget(collectionID int64) (chan struct{}, error)
Constants ¶
View Source
const ( UpdateCollection targetOp = iota + 1 ReleaseCollection ReleasePartition )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CollectionObserver ¶
type CollectionObserver struct {
// contains filtered or unexported fields
}
func NewCollectionObserver ¶
func NewCollectionObserver( dist *meta.DistributionManager, meta *meta.Meta, targetMgr meta.TargetManagerInterface, targetObserver *TargetObserver, checherController *checkers.CheckerController, proxyManager proxyutil.ProxyClientManagerInterface, ) *CollectionObserver
func (*CollectionObserver) LoadCollection ¶
func (ob *CollectionObserver) LoadCollection(ctx context.Context, collectionID int64)
func (*CollectionObserver) LoadPartitions ¶
func (ob *CollectionObserver) LoadPartitions(ctx context.Context, collectionID int64, partitionIDs []int64)
func (*CollectionObserver) Observe ¶
func (ob *CollectionObserver) Observe(ctx context.Context)
func (*CollectionObserver) Start ¶
func (ob *CollectionObserver) Start()
func (*CollectionObserver) Stop ¶
func (ob *CollectionObserver) Stop()
type CollectionShardLeaderCache ¶
type CollectionShardLeaderCache = map[string]*querypb.ShardLeadersList
type LeaderCacheObserver ¶
type LeaderCacheObserver struct {
// contains filtered or unexported fields
}
LeaderCacheObserver is to invalidate shard leader cache when leader location changes
func NewLeaderCacheObserver ¶
func NewLeaderCacheObserver( proxyManager proxyutil.ProxyClientManagerInterface, ) *LeaderCacheObserver
func (*LeaderCacheObserver) HandleEvent ¶
func (o *LeaderCacheObserver) HandleEvent(ctx context.Context, collectionIDs ...int64)
func (*LeaderCacheObserver) RegisterEvent ¶
func (o *LeaderCacheObserver) RegisterEvent(events ...int64)
func (*LeaderCacheObserver) Start ¶
func (o *LeaderCacheObserver) Start(ctx context.Context)
func (*LeaderCacheObserver) Stop ¶
func (o *LeaderCacheObserver) Stop()
type ReplicaObserver ¶
type ReplicaObserver struct {
// contains filtered or unexported fields
}
check replica, find read only nodes and remove it from replica if all segment/channel has been moved
func NewReplicaObserver ¶
func NewReplicaObserver(meta *meta.Meta, distMgr *meta.DistributionManager) *ReplicaObserver
func (*ReplicaObserver) Start ¶
func (ob *ReplicaObserver) Start()
func (*ReplicaObserver) Stop ¶
func (ob *ReplicaObserver) Stop()
type ResourceObserver ¶
type ResourceObserver struct {
// contains filtered or unexported fields
}
ResourceObserver is used to observe resource group status. Recover resource group into expected configuration.
func NewResourceObserver ¶
func NewResourceObserver(meta *meta.Meta) *ResourceObserver
func (*ResourceObserver) Start ¶
func (ob *ResourceObserver) Start()
func (*ResourceObserver) Stop ¶
func (ob *ResourceObserver) Stop()
type TargetObserver ¶
type TargetObserver struct {
// contains filtered or unexported fields
}
func NewTargetObserver ¶
func NewTargetObserver( meta *meta.Meta, targetMgr meta.TargetManagerInterface, distMgr *meta.DistributionManager, broker meta.Broker, cluster session.Cluster, nodeMgr *session.NodeManager, ) *TargetObserver
func (*TargetObserver) Check ¶
Check whether provided collection is has current target. If not, submit an async task into dispatcher.
func (*TargetObserver) ReleaseCollection ¶
func (ob *TargetObserver) ReleaseCollection(collectionID int64)
func (*TargetObserver) ReleasePartition ¶
func (ob *TargetObserver) ReleasePartition(collectionID int64, partitionID ...int64)
func (*TargetObserver) Start ¶
func (ob *TargetObserver) Start()
func (*TargetObserver) Stop ¶
func (ob *TargetObserver) Stop()
func (*TargetObserver) TriggerUpdateCurrentTarget ¶
func (ob *TargetObserver) TriggerUpdateCurrentTarget(collectionID int64)
func (*TargetObserver) UpdateNextTarget ¶
func (ob *TargetObserver) UpdateNextTarget(collectionID int64) (chan struct{}, error)
UpdateNextTarget updates the next target, returns a channel which will be closed when the next target is ready, or returns error if failed to pull target
Click to show internal directories.
Click to hide internal directories.