cloudwatch

package
v1.6.6 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	//ProviderType indicates the provider is cloudwatch
	ProviderType = "CloudWatch"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudWatchClient

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

func (*CloudWatchClient) Query

type CloudWatchClientAPI

type CloudWatchClientAPI interface {
	Query(interval time.Duration, query []types.MetricDataQuery) (*cloudwatch.GetMetricDataOutput, error)
}

func NewCloudWatchAPIClient

func NewCloudWatchAPIClient(metric v1alpha1.Metric, opts ...func(*cloudwatch.Options)) (CloudWatchClientAPI, error)

type Provider

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

Provider contains all the required components to run a CloudWatch query Implements the Provider Interface

func NewCloudWatchProvider

func NewCloudWatchProvider(api CloudWatchClientAPI, logCtx log.Entry) *Provider

NewCloudWatchProvider creates a new CloudWatch provider

func (*Provider) GarbageCollect

func (p *Provider) GarbageCollect(run *v1alpha1.AnalysisRun, metric v1alpha1.Metric, i int) error

func (*Provider) GetMetadata added in v1.2.0

func (p *Provider) GetMetadata(metric v1alpha1.Metric) map[string]string

GetMetadata returns any additional metadata which needs to be stored & displayed as part of the metrics result.

func (*Provider) Resume

func (p *Provider) Resume(run *v1alpha1.AnalysisRun, metric v1alpha1.Metric, measurement v1alpha1.Measurement) v1alpha1.Measurement

func (*Provider) Run

Run queries with CloudWatch provider for the metric

func (*Provider) Terminate

func (p *Provider) Terminate(run *v1alpha1.AnalysisRun, metric v1alpha1.Metric, measurement v1alpha1.Measurement) v1alpha1.Measurement

func (*Provider) Type

func (p *Provider) Type() string

Jump to

Keyboard shortcuts

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