types

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2025 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AllIntervals = []StreamInterval{
	PerMinute,
	Hourly,
	Daily,
}

Functions

This section is empty.

Types

type AppMode

type AppMode string

Modes

const (
	MenuMode           AppMode = "menu"
	MonitorMode        AppMode = "monitor"
	StreamMode         AppMode = "stream"
	StreamSettings     AppMode = "stream_settings"
	FormatSettings     AppMode = "format_settings"
	ProcessMgmtMode    AppMode = "process_management"
	BgStreamSettings   AppMode = "bg_stream_settings"
	BgIntervalSettings AppMode = "bg_interval_settings"
)

type BackgroundProcess

type BackgroundProcess struct {
	ID          string
	Name        string
	Status      ProcessStatus
	StartTime   time.Time
	LogFormat   LogFormat
	Interval    StreamInterval
	LogPath     string
	StreamCount int
	StopChannel chan bool
	DoneChannel chan bool
}

Background Process Management

type LogFormat

type LogFormat string

Log format types

const (
	OpenTelemetryFormat LogFormat = "OpenTelemetry (JSON)"
	OTLPTextLineFormat  LogFormat = "OTLP Text Line Protocol"
	PrometheusFormat    LogFormat = "Prometheus"
	JSONLinesFormat     LogFormat = "JSON Lines"
	InfluxDBFormat      LogFormat = "InfluxDB Line Protocol"
	CloudWatchFormat    LogFormat = "AWS CloudWatch"
	CSVFormat           LogFormat = "CSV (Comma-Separated Values)"
	TSVFormat           LogFormat = "TSV (Tab-Separated Values)"
	XMLFormat           LogFormat = "XML"
	YAMLFormat          LogFormat = "YAML"
	SyslogFormat        LogFormat = "Syslog (RFC 5424)"
)

type MetricType

type MetricType string

Metric types

const (
	CPUMetric     MetricType = "CPU Usage"
	MemoryMetric  MetricType = "Memory Info"
	DiskMetric    MetricType = "Disk Usage"
	NetworkMetric MetricType = "Network Stats"
	HostMetric    MetricType = "Host Info"
	AllMetrics    MetricType = "All Metrics"
)

type MetricsMsg

type MetricsMsg struct {
	CPU     string
	Memory  string
	Disk    string
	Network string
	Host    string
	Err     error
}

type ProcessAction

type ProcessAction string
const (
	StartProcess ProcessAction = "start"
	StopProcess  ProcessAction = "stop"
	ListProcess  ProcessAction = "list"
)

type ProcessControlMsg

type ProcessControlMsg struct {
	Action    ProcessAction
	ProcessID string
}

type ProcessListMsg

type ProcessListMsg struct {
	Processes []BackgroundProcess
}

type ProcessStatus

type ProcessStatus string
const (
	ProcessRunning ProcessStatus = "running"
	ProcessStopped ProcessStatus = "stopped"
	ProcessError   ProcessStatus = "error"
)

type StreamInterval

type StreamInterval string

Stream interval types

const (
	PerMinute StreamInterval = "Per Minute"
	Hourly    StreamInterval = "Hourly"
	Daily     StreamInterval = "Daily"
)

func (StreamInterval) Duration

func (si StreamInterval) Duration() time.Duration

type TickMsg

type TickMsg time.Time

Messages

Jump to

Keyboard shortcuts

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