constants

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package constants holds project-wide constants and build-time metadata.

Index

Constants

View Source
const (
	// AppName is the binary / command name.
	AppName = "openobserve-cli"

	// EnvPrefix is the environment variable prefix for all settings.
	EnvPrefix = "OPENOBSERVE_"

	// ConfigParentDirName groups every angelmsger CLI's per-user config under
	// one shared $HOME-relative directory (~/.angelmsger).
	ConfigParentDirName = ".angelmsger"

	// ConfigDirName is the per-CLI config directory under ConfigParentDirName,
	// i.e. ~/.angelmsger/openobserve.
	ConfigDirName = "openobserve"

	// ConfigFileName is the YAML config file within ConfigDirName.
	ConfigFileName = "config.yaml"

	// CredentialsFileName is the fallback secret store when no keychain is available.
	CredentialsFileName = "credentials"

	// KeychainService is the service name used for OS keychain entries.
	KeychainService = "openobserve-cli"
)
View Source
const (
	DefaultFormat     = "json"
	DefaultTimeout    = 30 * time.Second
	DefaultMaxRetries = 3

	// DefaultOrg is OpenObserve's built-in organization identifier.
	DefaultOrg = "default"

	// DefaultSearchLimit is the number of hits returned by `search run` when
	// --limit is not given. Kept modest so a stray query does not flood an
	// agent's context window.
	DefaultSearchLimit = 100

	// MaxSearchLimit caps a single search request's size.
	MaxSearchLimit = 10000

	// SelfHostedBaseURL is the default URL of a local OpenObserve install.
	SelfHostedBaseURL = "http://localhost:5080"

	// CloudBaseURL is the OpenObserve Cloud API root.
	CloudBaseURL = "https://api.openobserve.ai"
)

Defaults for runtime behaviour.

Variables

View Source
var (
	Version   = "dev"
	Commit    = "none"
	BuildTime = "unknown"
)

Build-time metadata, injected via -ldflags. See Makefile.

Functions

func UserAgent

func UserAgent() string

UserAgent identifies the CLI to the OpenObserve server.

Types

This section is empty.

Jump to

Keyboard shortcuts

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