agent

package
v0.1.29 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package agent provides domain models for the agent

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Capabilities added in v0.0.15

type Capabilities uint64

Capabilities is a bitmask of capabilities that the Agent supports. The Capabilities enum is defined in the opamp protocol.

func (*Capabilities) Has added in v0.0.15

func (a *Capabilities) Has(capability Capability) bool

Has checks if the AgentCapabilities has a specific capability.

func (*Capabilities) HasAcceptsOpAMPConnectionSettings added in v0.1.26

func (a *Capabilities) HasAcceptsOpAMPConnectionSettings() bool

HasAcceptsOpAMPConnectionSettings checks if the AgentCapabilities has the AcceptsOpAMPConnectionSettings capability.

func (*Capabilities) HasAcceptsPackages added in v0.1.26

func (a *Capabilities) HasAcceptsPackages() bool

HasAcceptsPackages checks if the AgentCapabilities has the AcceptsPackages capability.

func (*Capabilities) HasAcceptsRemoteConfig added in v0.1.24

func (a *Capabilities) HasAcceptsRemoteConfig() bool

HasAcceptsRemoteConfig checks if the AgentCapabilities has the AcceptsRemoteConfig capability.

func (*Capabilities) HasAcceptsRestartCommand added in v0.1.24

func (a *Capabilities) HasAcceptsRestartCommand() bool

HasAcceptsRestartCommand checks if the AgentCapabilities has the AcceptsRestartCommand capability.

func (*Capabilities) HasOtherConnectionSettings added in v0.1.26

func (a *Capabilities) HasOtherConnectionSettings() bool

HasOtherConnectionSettings checks if the AgentCapabilities has the AcceptsOtherConnectionSettings capability.

func (*Capabilities) HasReportsAvailableComponents added in v0.1.26

func (a *Capabilities) HasReportsAvailableComponents() bool

HasReportsAvailableComponents checks if the AgentCapabilities has the ReportsAvailableComponents capability.

func (*Capabilities) HasReportsEffectiveConfig added in v0.1.24

func (a *Capabilities) HasReportsEffectiveConfig() bool

HasReportsEffectiveConfig checks if the AgentCapabilities has the ReportsEffectiveConfig capability.

func (*Capabilities) HasReportsHealth added in v0.1.26

func (a *Capabilities) HasReportsHealth() bool

HasReportsHealth checks if the AgentCapabilities has the ReportsHealth capability.

func (*Capabilities) HasReportsHeartbeat added in v0.1.26

func (a *Capabilities) HasReportsHeartbeat() bool

HasReportsHeartbeat checks if the AgentCapabilities has the ReportsHeartbeat capability.

func (*Capabilities) HasReportsOwnLogs added in v0.1.26

func (a *Capabilities) HasReportsOwnLogs() bool

HasReportsOwnLogs checks if the AgentCapabilities has the ReportsOwnLogs capability.

func (*Capabilities) HasReportsOwnMetrics added in v0.1.26

func (a *Capabilities) HasReportsOwnMetrics() bool

HasReportsOwnMetrics checks if the AgentCapabilities has the ReportsOwnMetrics capability.

func (*Capabilities) HasReportsOwnTraces added in v0.1.26

func (a *Capabilities) HasReportsOwnTraces() bool

HasReportsOwnTraces checks if the AgentCapabilities has the ReportsOwnTraces capability.

func (*Capabilities) HasReportsPackageStatuses added in v0.1.26

func (a *Capabilities) HasReportsPackageStatuses() bool

HasReportsPackageStatuses checks if the AgentCapabilities has the ReportsPackageStatuses capability.

func (*Capabilities) HasReportsRemoteConfig added in v0.1.26

func (a *Capabilities) HasReportsRemoteConfig() bool

HasReportsRemoteConfig checks if the AgentCapabilities has the ReportsRemoteConfig capability.

func (*Capabilities) HasReportsStatus added in v0.0.15

func (a *Capabilities) HasReportsStatus() bool

HasReportsStatus checks if the AgentCapabilities has the ReportsStatus capability.

type Capability added in v0.0.15

type Capability uint64

Capability is a helper type to represent the capabilities of the Agent. It is used to define the capabilities of the Agent in a more readable way.

const (
	// AgentCapabilityUnspecified represents that
	// The capabilities field is unspecified.
	AgentCapabilityUnspecified Capability = 0
	// AgentCapabilityReportsStatus represents that
	// The Agent can report status. This bit MUST be set, since all Agents MUST
	// report status.
	AgentCapabilityReportsStatus Capability = 1
	// AgentCapabilityAcceptsRemoteConfig represents that
	// The Agent can accept remote configuration from the Server.
	AgentCapabilityAcceptsRemoteConfig Capability = 2
	// AgentCapabilityReportsEffectiveConfig represents that
	// The Agent will report EffectiveConfig in AgentToServer.
	AgentCapabilityReportsEffectiveConfig Capability = 4
	// AgentCapabilityAcceptsPackages represents that
	// The Agent can accept package offers.
	// Status: [Beta].
	AgentCapabilityAcceptsPackages Capability = 8
	// AgentCapabilityReportsPackageStatuses represents that
	// The Agent can report package status.
	// Status: [Beta].
	AgentCapabilityReportsPackageStatuses Capability = 16
	// AgentCapabilityReportsOwnTraces represents that
	// The Agent can report own trace to the destination specified by
	// the Server via ConnectionSettingsOffers.own_traces field.
	// Status: [Beta].
	AgentCapabilityReportsOwnTraces Capability = 32
	// AgentCapabilityReportsOwnMetrics represents that
	// The Agent can report own metrics to the destination specified by
	// the Server via ConnectionSettingsOffers.own_metrics field.
	// Status: [Beta].
	AgentCapabilityReportsOwnMetrics Capability = 64
	// AgentCapabilityReportsOwnLogs represents that
	// The Agent can report own logs to the destination specified by
	// the Server via ConnectionSettingsOffers.own_logs field.
	// Status: [Beta].
	AgentCapabilityReportsOwnLogs Capability = 128
	// AgentCapabilityAcceptsOpAMPConnectionSettings represents that
	// The can accept connections settings for OpAMP via
	// ConnectionSettingsOffers.opamp field.
	// Status: [Beta].
	AgentCapabilityAcceptsOpAMPConnectionSettings Capability = 256
	// AgentCapabilityAcceptsOtherConnectionSettings represents that
	// The can accept connections settings for other destinations via
	// ConnectionSettingsOffers.other_connections field.
	// Status: [Beta].
	AgentCapabilityAcceptsOtherConnectionSettings Capability = 512
	// AgentCapabilityAcceptsRestartCommand represents that
	// The Agent can accept restart requests.
	// Status: [Beta].
	AgentCapabilityAcceptsRestartCommand Capability = 1024
	// AgentCapabilityReportsHealth represents that
	// The Agent will report Health via AgentToServer.health field.
	AgentCapabilityReportsHealth Capability = 2048
	// AgentCapabilityReportsRemoteConfig represents that
	// The Agent will report RemoteConfig status via AgentToServer.remote_config_status field.
	AgentCapabilityReportsRemoteConfig Capability = 4096
	// AgentCapabilityReportsHeartbeat represents that
	// The Agent can report heartbeats.
	// This is specified by the ServerToAgent.OpAMPConnectionSettings.heartbeat_interval_seconds field.
	// If this capability is true, but the Server does not set a heartbeat_interval_seconds field, the
	// Agent should use its own configured interval, which by default will be 30s. The Server may not
	// know the configured interval and should not make assumptions about it.
	// Status: [Development].
	AgentCapabilityReportsHeartbeat Capability = 8192
	// AgentCapabilityReportsAvailableComponents represents that
	// The agent will report AvailableComponents via the AgentToServer.available_components field.
	// Status: [Development].
	AgentCapabilityReportsAvailableComponents Capability = 16384
)

type Description

type Description struct {
	IdentifyingAttributes    map[string]string
	NonIdentifyingAttributes map[string]string
}

Description represents the description of an agent. It contains identifying and non-identifying attributes.

func (*Description) Host

func (ad *Description) Host() Host

Host returns host information.

func (*Description) Service

func (ad *Description) Service() vo.Service

Service returns service information.

type Host

type Host struct {
	Name string
}

Host is a domain model that represents a host.

Jump to

Keyboard shortcuts

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