postgresreader

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2026 License: MIT Imports: 9 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package postgresreader stores and reads bounded periodic Runtime telemetry.

Index

Constants

View Source
const (
	CPUUsageName       = "cpu_usage_seconds"
	CPUCapacityName    = "cpu_capacity_cores"
	CPUUtilizationName = "cpu_utilization_ratio"
	MemoryUsageName    = "memory_usage_bytes"
	MemoryLimitName    = "memory_limit_bytes"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Capabilities runtimehistory.Capabilities
	QueryTimeout time.Duration
}

type Reader

type Reader struct {
	// contains filtered or unexported fields
}

func New

func New(store sampleStore, config Config) (*Reader, error)

func (*Reader) Capabilities

func (r *Reader) Capabilities() runtimehistory.Capabilities

func (*Reader) Export

func (r *Reader) Export(ctx context.Context, record runtimeobs.ExportRecord) error

func (*Reader) Prune

func (r *Reader) Prune(ctx context.Context) (int64, error)

Prune expires old telemetry even when no Runtime is being sampled. Each call deletes at most 8,192 Runtime and node-host rows in small lock-skipping batches under one deadline.

func (*Reader) Query

Jump to

Keyboard shortcuts

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