stressseed

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package stressseed fills a store with a deterministic, large resource graph for UI and stress measurement. Dev tooling only: never imported by the control plane.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Apps          int
	Databases     int
	Nodes         int
	Deploys       int
	EnvsPerApp    int
	DomainsPerApp int
	Seed          uint64
	// Anchor is the "now" that every timestamp is computed from; zero means the current time.
	Anchor time.Time
	// NodeIDs places apps round-robin on these existing nodes; empty leaves them on the local node.
	NodeIDs []string
}

Config sizes the graph. The same Seed and Anchor always produce the same rows.

type Manifest

type Manifest struct {
	Apps      []string
	Databases []string
	Nodes     []string
	Deploys   int
	Digest    string
}

Manifest names what a seed produced. Digest is a hash of every inserted row.

func Seed

func Seed(ctx context.Context, db *store.DB, cfg Config) (Manifest, error)

Seed inserts the graph in one transaction. It refuses a store that already holds the seeded app names.

Jump to

Keyboard shortcuts

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