cik_job

package module
v0.0.0-...-90d5130 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2022 License: MIT Imports: 2 Imported by: 0

README

分布式任务

Documentation

Overview

*

  • @Author: cloudintheking
  • @Description:
  • @File: job
  • @Version: 1.0.0
  • @Date: 2022/7/13 15:24

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddRunner

func AddRunner(c *cron.Cron, runner JobRunner) (cron.EntryID, error)

func JobDeserialize

func JobDeserialize(data []byte, target JobRunner) error

func JobSerialize

func JobSerialize(runner JobRunner) ([]byte, error)

Types

type JobRunner

type JobRunner interface {
	Call()           //执行函数
	GetCron() string //cron表达式
}

Jump to

Keyboard shortcuts

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