messages

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Kind

type Kind string
const (
	RebalanceRecommendationKind Kind = "rebalance_recommendation"
	ScheduledChangeKind         Kind = "scheduled_change"
	SpotInterruptionKind        Kind = "spot_interrupted"
	InstanceStoppedKind         Kind = "instance_stopped"
	InstanceTerminatedKind      Kind = "instance_terminated"
	NoOpKind                    Kind = "no_op"
)

type Message

type Message interface {
	EC2InstanceIDs() []string
	Kind() Kind
	StartTime() time.Time
}

type Metadata

type Metadata struct {
	Account    string    `json:"account"`
	DetailType string    `json:"detail-type"`
	ID         string    `json:"id"`
	Region     string    `json:"region"`
	Resources  []string  `json:"resources"`
	Source     string    `json:"source"`
	Time       time.Time `json:"time"`
	Version    string    `json:"version"`
}

func (Metadata) StartTime

func (m Metadata) StartTime() time.Time

type Parser

type Parser interface {
	Parse(string) (Message, error)

	Version() string
	Source() string
	DetailType() string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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