collector

package
v8.2.1+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2020 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

View Source
const (
	GaugeValue float64 = 1
)

Variables

This section is empty.

Functions

func IsInvalidConfig

func IsInvalidConfig(err error) bool

IsInvalidConfig asserts invalidConfigError.

func IsInvalidResource

func IsInvalidResource(err error) bool

IsInvalidResource asserts invalidResourceError.

func IsNilLimit

func IsNilLimit(err error) bool

IsNilLimit asserts nilLimitError.

func IsNilUsage

func IsNilUsage(err error) bool

IsNilUsage asserts nilUsageError.

func IsUnsupportedPlan

func IsUnsupportedPlan(err error) bool

IsUnsupportedPlan asserts that an error is due to Trusted Advisor not being available with the current support plan.

Types

type ASG

type ASG struct {
	// contains filtered or unexported fields
}

ASG is the main struct for this collector.

func NewASG

func NewASG(config ASGConfig) (*ASG, error)

NewASG creates a new AutoScalingGroup metrics collector.

func (*ASG) Collect

func (a *ASG) Collect(ch chan<- prometheus.Metric) error

Collect is the main metrics collection function.

func (*ASG) Describe

func (a *ASG) Describe(ch chan<- *prometheus.Desc) error

Describe emits the description for the metrics collected here.

type ASGConfig

type ASGConfig struct {
	Helper *helper
	Logger micrologger.Logger

	InstallationName string
}

ASGConfig is this collector's configuration struct.

type CloudFormation

type CloudFormation struct {
	// contains filtered or unexported fields
}

Main struct for this collector.

func NewCloudFormation

func NewCloudFormation(config CloudFormationConfig) (*CloudFormation, error)

Creates a new CloudFormation metrics collector.

func (*CloudFormation) Collect

func (cf *CloudFormation) Collect(ch chan<- prometheus.Metric) error

Collect is the main metrics collection function.

func (*CloudFormation) Describe

func (cf *CloudFormation) Describe(ch chan<- *prometheus.Desc) error

Describe emits the description for the metrics collected here.

type CloudFormationConfig

type CloudFormationConfig struct {
	Helper *helper
	Logger micrologger.Logger

	InstallationName string
}

Configuration struct.

type EC2Instances

type EC2Instances struct {
	// contains filtered or unexported fields
}

EC2Instances is the main struct for this collector.

func NewEC2Instances

func NewEC2Instances(config EC2InstancesConfig) (*EC2Instances, error)

NewEC2Instances creates a new EC2 instance metrics collector.

func (*EC2Instances) Collect

func (e *EC2Instances) Collect(ch chan<- prometheus.Metric) error

Collect is the main metrics collection function.

func (*EC2Instances) Describe

func (e *EC2Instances) Describe(ch chan<- *prometheus.Desc) error

Describe emits the description for the metrics collected here.

type EC2InstancesConfig

type EC2InstancesConfig struct {
	Helper *helper
	Logger micrologger.Logger

	InstallationName string
}

EC2InstancesConfig is this collector's configuration struct.

type ELB

type ELB struct {
	// contains filtered or unexported fields
}

func NewELB

func NewELB(config ELBConfig) (*ELB, error)

func (*ELB) Collect

func (e *ELB) Collect(ch chan<- prometheus.Metric) error

func (*ELB) Describe

func (e *ELB) Describe(ch chan<- *prometheus.Desc) error

type ELBConfig

type ELBConfig struct {
	Helper *helper
	Logger micrologger.Logger

	InstallationName string
}

type Set

type Set struct {
	*collector.Set
}

Set is basically only a wrapper for the operator's collector implementations. It eases the initialization and prevents some weird import mess so we do not have to alias packages. There is also the benefit of the helper type kept private so we do not need to expose this magic.

func NewSet

func NewSet(config SetConfig) (*Set, error)

type SetConfig

type SetConfig struct {
	G8sClient versioned.Interface
	K8sClient kubernetes.Interface
	Logger    micrologger.Logger

	AWSConfig             clientaws.Config
	InstallationName      string
	TrustedAdvisorEnabled bool
}

type TrustedAdvisor

type TrustedAdvisor struct {
	// contains filtered or unexported fields
}

func NewTrustedAdvisor

func NewTrustedAdvisor(config TrustedAdvisorConfig) (*TrustedAdvisor, error)

func (*TrustedAdvisor) Collect

func (t *TrustedAdvisor) Collect(ch chan<- prometheus.Metric) error

func (*TrustedAdvisor) Describe

func (t *TrustedAdvisor) Describe(ch chan<- *prometheus.Desc) error

type TrustedAdvisorConfig

type TrustedAdvisorConfig struct {
	Helper *helper
	Logger micrologger.Logger
}

type VPC

type VPC struct {
	// contains filtered or unexported fields
}

func NewVPC

func NewVPC(config VPCConfig) (*VPC, error)

func (*VPC) Collect

func (v *VPC) Collect(ch chan<- prometheus.Metric) error

func (*VPC) Describe

func (v *VPC) Describe(ch chan<- *prometheus.Desc) error

type VPCConfig

type VPCConfig struct {
	Helper *helper
	Logger micrologger.Logger

	InstallationName string
}

Jump to

Keyboard shortcuts

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