tasks

package
v0.0.0-...-fde5662 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const TypeResizeImage = "image:resize"

Variables

View Source
var StandardWidths = []uint{16, 32, 128, 240, 320, 480, 540, 640, 800, 1024}

Functions

func Close

func Close()

func GetClient

func GetClient() *asynq.Client

func HandleResizeImageTask

func HandleResizeImageTask(ctx context.Context, t *asynq.Task) error

func Init

func Init(redisAddress string)

func NewImageResizeTasks

func NewImageResizeTasks(imageData []byte, fileName string) ([]*asynq.Task, error)

Types

type ResizeImagePayload

type ResizeImagePayload struct {
	ImageData []byte
	Width     uint
	Height    uint
	FileName  string
}

Jump to

Keyboard shortcuts

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