Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OperatorManager ¶
type OperatorManager struct {
// contains filtered or unexported fields
}
func NewOperatorManager ¶
func NewOperatorManager(dispatcherId uuid.UUID, l *zerolog.Logger, repo repository.Repository, enc encryption.EncryptionService, infraBlockedCIDRs []string) *OperatorManager
func (*OperatorManager) Cleanup ¶
func (om *OperatorManager) Cleanup()
func (*OperatorManager) HandleAction ¶
func (om *OperatorManager) HandleAction(ctx context.Context, operatorId uuid.UUID, action *contracts.AssignedAction) error
func (*OperatorManager) Start ¶
func (om *OperatorManager) Start(ctx context.Context, taskEventWriter operator.TaskEventWriter) <-chan []operator.Operator
Start begins polling for operators. taskEventWriter is the sink operators use to report task results back through the dispatcher (the DispatcherImpl itself satisfies it); it is passed here rather than to the constructor because the dispatcher isn't fully built when the manager is created.
The returned channel carries the full set of active operators on every poll; consumers should treat each message as the desired state and remove anything no longer present.
Click to show internal directories.
Click to hide internal directories.