taskqueue

package
v1.23.0 Latest Latest
Warning

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

Go to latest
Published: May 13, 2026 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dst

type Dst struct {
	db.WithDatabase
	Address    string   `help:"Redis URL for task queue" default:"redis://localhost:6379"`
	Stream     string   `arg:"" help:"Redis stream name" default:"balancer"`
	Attributes []string `help:"Node attributes to display" default:"tag:server_group,tag:host,tag:service"`
}

Dst prints a histogram of destination nodes in the task queue.

func (*Dst) Run

func (d *Dst) Run() error

type Keys

type Keys struct {
	Address string `help:"Redis URL for task queue" default:"redis://localhost:6379"`
}

Keys lists all Redis stream keys and their lengths.

func (*Keys) Run

func (k *Keys) Run() error

type Src

type Src struct {
	db.WithDatabase
	Address    string   `help:"Redis URL for task queue" default:"redis://localhost:6379"`
	Stream     string   `arg:"" help:"Redis stream name" default:"balancer"`
	Attributes []string `help:"Node attributes to display" default:"tag:server_group,tag:host,tag:service"`
}

Src prints a histogram of source nodes in the task queue.

func (*Src) Run

func (s *Src) Run() error

type Stat

type Stat struct {
	Address  string `help:"redis URL for task queue" default:"redis://localhost:6379"`
	StreamID string `help:"Redis stream name" default:"balancer"`
}

Stat reads all entries from a Redis stream and prints per source_node->dest_node pair counts.

func (Stat) Run

func (s Stat) Run() error

type TaskQueue

type TaskQueue struct {
	Keys Keys `cmd:"" help:"List all stream keys and their sizes."`
	Stat Stat `cmd:"" help:"Show summary statistics of the task queue."`
	Src  Src  `cmd:"" help:"Show histogram of source nodes in the task queue."`
	Dst  Dst  `cmd:"" help:"Show histogram of destination nodes in the task queue."`
}

TaskQueue contains subcommands for inspecting the balancer task queue.

Jump to

Keyboard shortcuts

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