Help us shape the future of Go! Take the 2026 Go Developer Survey

client

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2022 License: BSD-3-Clause Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HttpWorker added in v1.0.4

func HttpWorker(spec string, option model.HttpJob) (job *api.Job, err error)

HttpWorker HTTP回调 @spec Crontab 规则 @option HTTP 配置

Types

type Schedule

type Schedule struct {
	// contains filtered or unexported fields
}

func New

func New(addr string, opts ...grpc.DialOption) (x *Schedule, err error)

func (*Schedule) Close

func (x *Schedule) Close() error

func (*Schedule) Delete

func (x *Schedule) Delete(ctx context.Context, key string) (err error)

Delete 删除任务 @key 唯一标识

func (*Schedule) Get

func (x *Schedule) Get(ctx context.Context, keys []string) (data map[string]*api.Schedule, err error)

Get 获取任务 @keys 唯一标识数组

func (*Schedule) Put

func (x *Schedule) Put(ctx context.Context, key string, jobs ...*api.Job) (err error)

Put 更新任务 @key 唯一标识 @jobs 工作流

Jump to

Keyboard shortcuts

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