Documentation ¶
Index ¶
- type SchedulerService
- func (s *SchedulerService) AddHost(host *types.Host) (ret *types.Host, err error)
- func (s *SchedulerService) AddPeerTask(pid string, task *types.Task, host *types.Host) (ret *types.PeerTask, err error)
- func (s *SchedulerService) AddTask(task *types.Task) (*types.Task, error)
- func (s *SchedulerService) DeletePeerTask(peerTaskID string) (err error)
- func (s *SchedulerService) GenerateTaskID(url string, filter string, meta *base.UrlMeta, bizID string, peerID string) (taskID string)
- func (s *SchedulerService) GetHost(hostID string) (host *types.Host, err error)
- func (s *SchedulerService) GetPeerTask(peerTaskID string) (peerTask *types.PeerTask, err error)
- func (s *SchedulerService) GetTask(taskID string) (*types.Task, bool)
- func (s *SchedulerService) ScheduleChildren(task *types.PeerTask) (children []*types.PeerTask, err error)
- func (s *SchedulerService) ScheduleParent(task *types.PeerTask) (primary *types.PeerTask, secondary []*types.PeerTask, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SchedulerService ¶
type SchedulerService struct { CDNManager *manager.CDNManager TaskManager *manager.TaskManager HostManager *manager.HostManager Scheduler *scheduler.Scheduler ABTest bool // contains filtered or unexported fields }
func NewSchedulerService ¶
func NewSchedulerService(cfg *config.Config, dynconfig config.DynconfigInterface) (*SchedulerService, error)
func (*SchedulerService) AddHost ¶
func (*SchedulerService) AddPeerTask ¶
func (*SchedulerService) AddTask ¶
func (*SchedulerService) DeletePeerTask ¶
func (s *SchedulerService) DeletePeerTask(peerTaskID string) (err error)
func (*SchedulerService) GenerateTaskID ¶
func (*SchedulerService) GetHost ¶
func (s *SchedulerService) GetHost(hostID string) (host *types.Host, err error)
func (*SchedulerService) GetPeerTask ¶
func (s *SchedulerService) GetPeerTask(peerTaskID string) (peerTask *types.PeerTask, err error)
func (*SchedulerService) GetTask ¶
func (s *SchedulerService) GetTask(taskID string) (*types.Task, bool)
func (*SchedulerService) ScheduleChildren ¶
Click to show internal directories.
Click to hide internal directories.