Documentation ¶
Index ¶
Constants ¶
View Source
const ( ErrDataError = 1000 + iota ErrInputError )
View Source
const (
ErrDbError = 2000 + iota
)
View Source
const ErrOk = 0
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PoliteVisitor ¶
type PoliteVisitor struct {
// contains filtered or unexported fields
}
func InitPoliteVisitor ¶
func InitPoliteVisitor(pool *pool.Pool, minVisitInterval int64) *PoliteVisitor
func (*PoliteVisitor) GetLastVisitTime ¶
func (this *PoliteVisitor) GetLastVisitTime(domain string, hostname string) int64
hget hostname domain
func (*PoliteVisitor) IsPolite ¶
func (this *PoliteVisitor) IsPolite(domain string, hostname string) bool
a convenient wrapper
func (*PoliteVisitor) SetLastVisitTime ¶
func (this *PoliteVisitor) SetLastVisitTime(domain string, hostname string, ts int64) error
hset hostname domain ts
type Scheduler ¶
type Scheduler struct {
// contains filtered or unexported fields
}
func (*Scheduler) FetchTasks ¶
获取等待调度的任务
Click to show internal directories.
Click to hide internal directories.