Documentation ¶
Index ¶
- Constants
- func IsInvalidConfig(err error) bool
- func IsInvalidResource(err error) bool
- func IsNilLimit(err error) bool
- func IsNilUsage(err error) bool
- func IsUnsupportedPlan(err error) bool
- type ASG
- type ASGConfig
- type EC2Instances
- type EC2InstancesConfig
- type ELB
- type ELBConfig
- type Set
- type SetConfig
- type TrustedAdvisor
- type TrustedAdvisorConfig
- type VPC
- type VPCConfig
Constants ¶
const (
GaugeValue float64 = 1
)
Variables ¶
This section is empty.
Functions ¶
func IsInvalidConfig ¶
IsInvalidConfig asserts invalidConfigError.
func IsInvalidResource ¶
IsInvalidResource asserts invalidResourceError.
func IsUnsupportedPlan ¶
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.
type ASGConfig ¶
type ASGConfig struct { Helper *helper Logger micrologger.Logger InstallationName string }
ASGConfig is this collector's 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 ELBConfig ¶
type ELBConfig struct { Helper *helper Logger micrologger.Logger InstallationName string }
type Set ¶
Set is basically only a wrapper for the operator's collector implementations. It eases the iniitialization 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.
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 VPCConfig ¶
type VPCConfig struct { Helper *helper Logger micrologger.Logger InstallationName string }