Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DefaultOptions = func() Options { return Options{ MaxRetry: 16, FetchCheckSec: 5, FetchForwardSec: 60, FetchPerCount: 128, RetryCheckSec: 60, RetryForwardSec: 600, RetryPerCount: 1024, } } )
View Source
var (
ErrNoneHandler = errors.New(`not found handler, please register handler`)
)
Functions ¶
This section is empty.
Types ¶
type Delay ¶
type Delay interface {
Set(ctx context.Context, item Item) (err error)
SetDead(ctx context.Context, item Item) (err error)
Done(ctx context.Context, items ...Item) (err error)
DeadList(ctx context.Context, offset, count int64) (items []Item, err error)
RegisterHandler(handler Handler)
Start() error
Stop(timeout time.Duration) error
}
type Item ¶
type Options ¶
type Options struct {
MaxRetry int64 `json:"maxRetry" yaml:"maxRetry"`
FetchCheckSec int64 `json:"fetchCheckSec" yaml:"fetchCheckSec"`
FetchPerCount int64 `json:"fetchPerCount" yaml:"fetchPerCount"`
FetchForwardSec int64 `json:"fetchForwardSec" yaml:"fetchForwardSec"`
RetryCheckSec int64 `json:"retryCheckSec" yaml:"retryCheckSec"`
RetryPerCount int64 `json:"retryPerCount" yaml:"retryPerCount"`
RetryForwardSec int64 `json:"retryForwardSec" yaml:"retryForwardSec"`
}
func (*Options) FetchCheck ¶
func (*Options) FetchForwardBeginAt ¶
func (*Options) RetryCheck ¶
func (*Options) RetryForwardEndAt ¶
Click to show internal directories.
Click to hide internal directories.