contract

package
v0.0.0-...-ba59bca Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 14, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CodeSuccess int32 = iota
	CodeFailed
	CodeNotFound
	CodeNotSupported
	CodeTaskIsRunning
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Batch

type Batch struct {
	Id   string
	Args data.Options
}

type ExecuteParam

type ExecuteParam struct {
	Name string       `json:"name"`
	Args data.Options `json:"args,omitempty"`
}

type Job

type Job struct {
	Id      string       `json:"id"`
	Task    string       `json:"task"`
	Handler string       `json:"handler"`
	Args    data.Options `json:"args"`
	Mode    int32        `json:"mode"` // 0-auto, 1-manual
	Fire    int64        `json:"fire"` // unix milliseconds
}

func (*Job) String

func (j *Job) String() string

type NotifyParam

type NotifyParam struct {
	Code  int32  `json:"code"`
	Info  string `json:"info,omitempty"`
	Id    string `json:"id,omitempty"`
	Start int64  `json:"start,omitempty"` // unix milliseconds
	End   int64  `json:"end,omitempty"`   // unix milliseconds
}

type Result

type Result struct {
	Code int32  `json:"code"`
	Info string `json:"info,omitempty"`
}

type SplitResult

type SplitResult struct {
	Code    int32  `json:"code"` // 0-成功, 1-失败, 2-不支持拆分
	Info    string `json:"info,omitempty"`
	Batches []*Batch
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL