message

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArangoEventNotificationMessage

type ArangoEventNotificationMessage struct {
	BaseResultMessage
	EventMessages []EventMessage
	Action        string
}

type ArangoNormalizationMessage

type ArangoNormalizationMessage struct {
	BaseResultMessage
	Measurement           string
	NormalizationMessages []NormalizationMessage
}

type ArangoUpdate

type ArangoUpdate struct {
	Tags   map[string]string
	Fields []string
	Values []float64
}

func NewArangoUpdate

func NewArangoUpdate(tags map[string]string) ArangoUpdate

type ArangoUpdateCommand

type ArangoUpdateCommand struct {
	BaseCommand
	Collection      string
	StatisticalData map[string]float64
	Updates         map[string]ArangoUpdate
}

func NewArangoUpdateCommand

func NewArangoUpdateCommand(collection string) *ArangoUpdateCommand

type BaseCommand

type BaseCommand struct{}

type BaseResultMessage

type BaseResultMessage struct{}

type Command

type Command interface {
	// contains filtered or unexported methods
}

type EventMessage

type EventMessage struct {
	Key       string
	Id        string
	TopicType int
}

type IPv6Fields

type IPv6Fields struct {
	Delete       bool   `mapstructure:"delete"`
	IPv6         string `mapstructure:"state/ip" validate:"required"`
	Origin       string `mapstructure:"state/origin" validate:"required"`
	PrefixLength int    `mapstructure:"state/prefix_length" validate:"required"`
	Status       string `mapstructure:"state/status" validate:"required"`
}

type IPv6Message

type IPv6Message struct {
	TelemetryMessage
	Fields IPv6Fields
}

type InfluxQueryCommand

type InfluxQueryCommand struct {
	BaseCommand
	Measurement    string
	Field          string
	Method         string
	Transformation *config.Transformation
	GroupBy        []string
	Interval       uint
	OutputOptions  map[string]config.OutputOption
}

type InfluxResult

type InfluxResult struct {
	Tags  map[string]string
	Value float64
}

type InfluxResultMessage

type InfluxResultMessage struct {
	BaseResultMessage
	OutputOptions map[string]config.OutputOption
	Results       []InfluxResult
}

type InterfaceStatusFields

type InterfaceStatusFields struct {
	AdminStatus             string `mapstructure:"admin_status" validate:"required"`
	CarrierTransitionsCount int    `mapstructure:"counters/carrier_transitions" validate:"min=0"`
	CPU                     string `mapstructure:"cpu" validate:"required"`
	Delete                  bool   `mapstructure:"delete"`
	Description             string `mapstructure:"description" validate:"required"`
	Enabled                 string `mapstructure:"enabled" validate:"required"`
	InterfaceIndex          int    `mapstructure:"ifindex" validate:"min=0"`
	LastChange              int64  `mapstructure:"last_change" validate:"required"`
	Logical                 string `mapstructure:"logical" validate:"required"`
	LoopbackMode            string `mapstructure:"loopback_mode" validate:"required"`
	Management              string `mapstructure:"management" validate:"required"`
	MTU                     int    `mapstructure:"mtu" validate:"required"`
	Name                    string `mapstructure:"name" validate:"required"`
	OperStatus              string `mapstructure:"oper_status" validate:"required"`
	Type                    string `mapstructure:"type" validate:"required"`
}

type InterfaceStatusMessage

type InterfaceStatusMessage struct {
	TelemetryMessage
	Fields InterfaceStatusFields
}

type KafkaEventCommand

type KafkaEventCommand struct {
	BaseCommand
	Updates []KafkaEventMessage
}

type KafkaEventMessage

type KafkaEventMessage struct {
	TopicType int    `json:"TopicType"`
	Key       string `json:"_key"`
	Id        string `json:"_id"`
	Action    string `json:"action"`
}

type KafkaListeningCommand

type KafkaListeningCommand struct{ BaseCommand }

type KafkaNormalizationCommand

type KafkaNormalizationCommand struct {
	BaseCommand
	Updates []KafkaNormalizationMessage
}

type KafkaNormalizationMessage

type KafkaNormalizationMessage struct {
	Measurement string
	Tags        map[string]string
	Fields      map[string]float64
}

type MessageTags

type MessageTags struct {
	Host          string `json:"host,omitempty"`
	Index         string `json:"index"`
	IP            string `json:"ip"`
	InterfaceName string `json:"name,omitempty"`
	Node          string `json:"node"`
	Path          string `json:"path,omitempty"`
	Source        string `json:"source,omitempty"`
	Subscription  string `json:"subscription,omitempty"`
}

type NormalizationMessage

type NormalizationMessage struct {
	Tags   map[string]string
	Fields map[string]float64
}

type Result

type Result interface {
	// contains filtered or unexported methods
}

type TelemetryMessage

type TelemetryMessage struct {
	BaseResultMessage
	Fields    map[string]interface{} `json:"fields,omitempty"`
	Name      string                 `json:"name,omitempty"`
	Tags      MessageTags            `json:"tags,omitempty"`
	Timestamp int64                  `json:"timestamp,omitempty"`
}

type UpdateLinkMessage

type UpdateLinkMessage struct {
	arango.LSLink
	NormalizedUnidirLinkDelay      float64 `json:"normalized_unidir_link_delay,omitempty"`
	NormalizedUnidirDelayVariation float64 `json:"normalized_unidir_delay_variation,omitempty"`
	NormalizedUnidirPacketLoss     float64 `json:"normalized_unidir_packet_loss,omitempty"`
	UnidirPacketLossPercentage     float64 `json:"undir_packet_loss_percentage,omitempty"`
}

func (*UpdateLinkMessage) GetFields

func (updateMessage *UpdateLinkMessage) GetFields() map[string]interface{}

Jump to

Keyboard shortcuts

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