postgres

package
v0.16.0 Latest Latest
Warning

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

Go to latest
Published: May 21, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Generator

type Generator struct {
	embed.ProducerMarker
	// contains filtered or unexported fields
}

Generator generates PostgreSQL log format log data

func New

func New(logger *zap.Logger, workers int, rate time.Duration, consumer embed.LogConsumer) (*Generator, error)

New creates a new PostgreSQL log generator. The consumer receives each generated record as a size-1 batch via ConsumeLogs.

func (*Generator) Name added in v0.16.0

func (g *Generator) Name() string

Name returns the module identifier.

func (*Generator) SetCountTracker added in v0.13.0

func (g *Generator) SetCountTracker(t *count.Tracker)

SetCountTracker sets the finite generation count tracker.

func (*Generator) Start

func (g *Generator) Start(_ context.Context) error

Start launches the worker goroutines that push generated records to the configured consumer.

func (*Generator) Stop

func (g *Generator) Stop(ctx context.Context) error

Stop stops the PostgreSQL log generator and waits for all workers to finish.

func (*Generator) SupportedTelemetry added in v0.16.0

func (g *Generator) SupportedTelemetry() []telemetry.Type

SupportedTelemetry returns the telemetry types this generator produces.

Jump to

Keyboard shortcuts

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