Documentation ¶
Overview ¶
Package cloudwatch defines structures for interacting with Cloudwatch Metrics.
Index ¶
Constants ¶
View Source
const DefaultConcurrency = 4
View Source
const DefaultExpansionLimit = 500
View Source
const DefaultPageLimit = 10
Variables ¶
View Source
var ErrExpansionLimit = errors.New("Hit dimension expansion limit")
View Source
var ErrInvalidPeriod = errors.New("Period must be greater than 0")
View Source
var ErrPagingLimit = errors.New("Hit the page limit when retrieving metrics")
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context interface { Query(*Request) (Response, error) LookupDimensions(request *LookupRequest) ([][]Dimension, error) GetExpansionLimit() int GetPagesLimit() int GetConcurrency() int }
Context is the interface for querying CloudWatch.
func GetContext ¶
func GetContext() Context
func GetContextWithProvider ¶
func GetContextWithProvider(p ProfileProvider) Context
type DimensionList ¶
type DimensionList struct {
Groups [][]Dimension
}
type DimensionSet ¶
type LookupRequest ¶
type ProfileProvider ¶
type ProfileProvider interface {
NewProfile(name, region string) cwi.CloudWatchAPI
}
type Request ¶
type Request struct { Start *time.Time End *time.Time Region string Namespace string Metric string Period int64 Statistic string DimensionString string Dimensions [][]Dimension Profile string }
Request holds query objects. Currently only absolute times are supported.
Click to show internal directories.
Click to hide internal directories.