Documentation
¶
Index ¶
- type Option
- type RunnerOption
- type RunnerV2
- type ServiceV2
- func (svc *ServiceV2) Cancel(taskId primitive.ObjectID) (err error)
- func (svc *ServiceV2) Fetch()
- func (svc *ServiceV2) GetCancelTimeout() (timeout time.Duration)
- func (svc *ServiceV2) GetCurrentNode() (n *models2.NodeV2, err error)
- func (svc *ServiceV2) GetExitWatchDuration() (duration time.Duration)
- func (svc *ServiceV2) GetFetchInterval() (interval time.Duration)
- func (svc *ServiceV2) GetNodeConfigService() (cfgSvc interfaces.NodeConfigService)
- func (svc *ServiceV2) GetReportInterval() (interval time.Duration)
- func (svc *ServiceV2) GetSpiderById(id primitive.ObjectID) (s *models2.SpiderV2, err error)
- func (svc *ServiceV2) GetTaskById(id primitive.ObjectID) (t *models2.TaskV2, err error)
- func (svc *ServiceV2) IsSyncLocked(path string) (ok bool)
- func (svc *ServiceV2) LockSync(path string)
- func (svc *ServiceV2) ReportStatus()
- func (svc *ServiceV2) Reset()
- func (svc *ServiceV2) Run(taskId primitive.ObjectID) (err error)
- func (svc *ServiceV2) SetCancelTimeout(timeout time.Duration)
- func (svc *ServiceV2) SetExitWatchDuration(duration time.Duration)
- func (svc *ServiceV2) SetFetchInterval(interval time.Duration)
- func (svc *ServiceV2) SetReportInterval(interval time.Duration)
- func (svc *ServiceV2) Start()
- func (svc *ServiceV2) UnlockSync(path string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Option ¶
type Option func(svc interfaces.TaskHandlerService)
func WithCancelTimeout ¶
func WithConfigPath ¶
func WithExitWatchDuration ¶
func WithReportInterval ¶
type RunnerOption ¶
type RunnerOption func(r interfaces.TaskRunner)
func WithSubscribeTimeout ¶
func WithSubscribeTimeout(timeout time.Duration) RunnerOption
type RunnerV2 ¶
type RunnerV2 struct {
// contains filtered or unexported fields
}
func NewTaskRunnerV2 ¶
func (*RunnerV2) SetSubscribeTimeout ¶
type ServiceV2 ¶
type ServiceV2 struct {
// contains filtered or unexported fields
}
func GetTaskHandlerServiceV2 ¶
func (*ServiceV2) GetCancelTimeout ¶
func (*ServiceV2) GetCurrentNode ¶
func (*ServiceV2) GetExitWatchDuration ¶
func (*ServiceV2) GetFetchInterval ¶
func (*ServiceV2) GetNodeConfigService ¶
func (svc *ServiceV2) GetNodeConfigService() (cfgSvc interfaces.NodeConfigService)
func (*ServiceV2) GetReportInterval ¶
func (*ServiceV2) GetSpiderById ¶
func (*ServiceV2) GetTaskById ¶
func (*ServiceV2) IsSyncLocked ¶
func (*ServiceV2) ReportStatus ¶
func (svc *ServiceV2) ReportStatus()
func (*ServiceV2) SetCancelTimeout ¶
func (*ServiceV2) SetExitWatchDuration ¶
func (*ServiceV2) SetFetchInterval ¶
func (*ServiceV2) SetReportInterval ¶
func (*ServiceV2) UnlockSync ¶
Click to show internal directories.
Click to hide internal directories.