dao

package
v0.0.0-...-66c98c8 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrQueueTypeDup = errors.ConflictError(nil).WithMessage("duplicated queue type")

ErrQueueTypeDup ...

Functions

This section is empty.

Types

type DAO

type DAO interface {
	// Query query queue status
	Query(ctx context.Context, query *q.Query) ([]*model.JobQueueStatus, error)
	// GetByJobType get queue status by JobType
	GetByJobType(ctx context.Context, jobType string) (*model.JobQueueStatus, error)
	// UpdateStatus update queue status
	UpdateStatus(ctx context.Context, jobType string, paused bool) error
	// InsertOrUpdate create a queue status or update it if it already exists
	InsertOrUpdate(ctx context.Context, queue *model.JobQueueStatus) (int64, error)
}

DAO the dao for queue status

func New

func New() DAO

New create queue status DAO

Jump to

Keyboard shortcuts

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