Documentation ¶
Overview ¶
Package rds implements methods to retrieve RDS information
Index ¶
Constants ¶
View Source
const ( InstanceStatusAvailable int = 1 InstanceStatusBackingUp int = 2 InstanceStatusStarting int = 3 InstanceStatusModifying int = 4 InstanceStatusStopped int = 0 InstanceStatusUnknown int = -1 InstanceStatusStopping int = -2 InstanceStatusCreating int = -3 InstanceStatusDeleting int = -4 NoPendingMaintenanceOperation string = "no" UnknownMaintenanceOperation string = "unknown" UnscheduledPendingMaintenanceOperation string = "pending" AutoAppliedPendingMaintenanceOperation string = "auto-applied" ForcedPendingMaintenanceOperation string = "forced" )
Variables ¶
This section is empty.
Functions ¶
func GetDBIdentifierFromARN ¶
GetDBIdentifierFromARN returns instance identifier from its ARN
func GetDBInstanceStatusCode ¶
GetDBInstanceStatusCode returns instance status numeric code
Types ¶
type Configuration ¶
type Metrics ¶
type Metrics struct {
Instances map[string]RdsInstanceMetrics
}
type RDSClient ¶
type RDSClient interface { DescribeDBInstances(ctx context.Context, params *aws_rds.DescribeDBInstancesInput, optFns ...func(*aws_rds.Options)) (*aws_rds.DescribeDBInstancesOutput, error) DescribePendingMaintenanceActions(context.Context, *aws_rds.DescribePendingMaintenanceActionsInput, ...func(*aws_rds.Options)) (*aws_rds.DescribePendingMaintenanceActionsOutput, error) DescribeDBLogFiles(context.Context, *aws_rds.DescribeDBLogFilesInput, ...func(*aws_rds.Options)) (*aws_rds.DescribeDBLogFilesOutput, error) }
type RDSFetcher ¶
type RDSFetcher struct {
// contains filtered or unexported fields
}
func NewFetcher ¶
func NewFetcher(ctx context.Context, client RDSClient, configuration Configuration) RDSFetcher
func (*RDSFetcher) GetInstancesMetrics ¶
func (r *RDSFetcher) GetInstancesMetrics() (Metrics, error)
func (*RDSFetcher) GetStatistics ¶
func (r *RDSFetcher) GetStatistics() Statistics
type RdsInstanceMetrics ¶
type RdsInstanceMetrics struct { Arn string Engine string EngineVersion string DBInstanceClass string DbiResourceID string StorageType string AllocatedStorage int64 StorageThroughput int64 MaxAllocatedStorage int64 MaxIops int64 LogFilesSize *int64 PendingMaintenanceAction string PendingModifiedValues bool BackupRetentionPeriod int32 Status int DeletionProtection bool PubliclyAccessible bool PerformanceInsightsEnabled bool MultiAZ bool IAMDatabaseAuthenticationEnabled bool Role string SourceDBInstanceIdentifier string CACertificateIdentifier string CertificateValidTill *time.Time Age *float64 Tags map[string]string }
type Statistics ¶
type Statistics struct {
RdsAPICall float64
}
Click to show internal directories.
Click to hide internal directories.