db

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2016 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActionLogEntry

type ActionLogEntry struct {
	Timestamp int64
	Message   string
	Details   string
	User      string
}

type BackupResponse

type BackupResponse struct {
	Id         int64
	FileName   string
	BackupTime int64
	Status     string
	Size       int64
}

type BackupTime

type BackupTime struct {
	Hour   *int64 `json:"hour,omitempty"`
	Minute *int64 `json:"minute,omitempty"`
}

type CertFile

type CertFile struct {
	Path          string
	Name          string
	Parent        string
	Absolute      bool
	CanonicalPath string
	ParentFile    *CertFile
	AbsolutePath  string
	AbsoluteFile  *CertFile
	CanonicalFile *CertFile
	Directory     bool
	File          bool
	Hidden        bool
	TotalSpace    int64
	FreeSpace     int64
	UsableSpace   int64
}

type Certificate

type Certificate struct {
	InputStream interface{}
	Description string
	Open        bool
	Filename    string
	Readable    bool
	File        CertFile
}

type Create

type Create struct {
	InstanceType        string               `valid:"required" oneOf:"MySQL,MySQL_REPLICATION" json:"instanceType"`
	ExternalId          string               `valid:"required" json:"externalId"`
	MachineConfig       MachineConfig        `json:"machineConfig"`
	BackupRetentionDays int64                `valid:"required" json:"backupRetentionDays"`
	Users               []User               `json:"users"`
	DataCenter          string               `json:"location"`
	Destinations        []DestinationRequest `json:"destinations,omitempty"`
	Instances           []Instance           `json:"instances,omitempty"`
	BackupTime          BackupTime           `json:"-"`
	BackupTimeValue     *BackupTime          `json:"backupTime,omitempty" argument:ignore`
}

func (*Create) Validate

func (c *Create) Validate() error

type CreateNotification

type CreateNotification struct {
	SubscriptionId     string `json:"-" URIParam:"yes" valid:"required"`
	DestinationRequest `argument:"composed"`
}

func (*CreateNotification) Validate

func (c *CreateNotification) Validate() error

type CreateRes

type CreateRes struct {
	Id                  int64
	Location            string
	InstanceType        string
	ExternalId          string
	Status              string
	BackupTime          string
	BackupRetentionDays int64
	OptionGroup         string
	ParameterGroup      string
	Users               []User
	Instances           []Instance
	Servers             []Server
	Host                string
	Port                int64
	Certificate         string
	Backups             []BackupResponse
}

type DataCenterInfo

type DataCenterInfo struct {
	DataCenter   string
	FriendlyName string
	Active       bool
}

type DeleteBackup

type DeleteBackup struct {
	SubscriptionId string `json:"-" URIParam:"yes" valid:"required"`
	BackupId       string `json:"-" URIParam:"yes" valid:"required"`
}

type DeleteNotification

type DeleteNotification struct {
	DestinationId  string `json:"-" URIParam:"yes" valid:"required"`
	SubscriptionId string `json:"-" URIParam:"yes" valid:"required"`
}

type Destination

type Destination struct {
	Id              int64
	DestinationType string
	Location        string
	Notifications   []Notification
	Verified        bool
}

type DestinationRequest

type DestinationRequest struct {
	DestinationType string                `oneOf:"EMAIL,SMS" json:"destinationType"`
	Location        string                `json:"location"`
	Notifications   []NotificationRequest `json:"notifications"`
}

type Get

type Get struct {
	SubscriptionId string `json:"-" URIParam:"yes" valid:"required"`
}

type Instance

type Instance struct {
	Name string `json:"name"`
}

type List

type List struct {
	Status     string `json:"-" URIParam:"yes" oneOf:"PENDING,READY,ACTIVE,DELETED,FAILED,UNKNOWN,SUCCESS,CONFIGURING,TERMINATED"`
	DataCenter string `json:"-" URIParam:"yes"`
}

type ListRes

type ListRes []CreateRes

type MachineConfig

type MachineConfig struct {
	Cpu     *int64 `json:"cpu,omitempty"`
	Memory  *int64 `json:"memory,omitempty"`
	Storage *int64 `json:"storage,omitempty"`
}

type Notification

type Notification struct {
	Id               int64
	NotificationType string
}

type NotificationRequest

type NotificationRequest struct {
	NotificationType string `oneOf:"CPU_UTILIATION,MEMORY_UTILIZATION,STORAGE_UTILIZATION" json:"notificationType"`
}

type Promotion

type Promotion struct {
	Id   int64
	Code string
}

type Server

type Server struct {
	Id          int64
	Alias       string
	Location    string
	Cpu         int64
	Memory      int64
	Storage     int64
	Attributes  map[string]string
	Connections int64
}

type Update

type Update struct {
	SubscriptionId      string         `json:"-" URIParam:"yes" valid:"required"`
	MachineConfig       MachineConfig  `json:"-"`
	MachineConfigValue  *MachineConfig `json:"machineConfig,omitempty" argument:"ignore"`
	BackupRetentionDays *int64         `json:"backupRetentionDays,omitempty"`
	BackupTime          BackupTime     `json:"-"`
	BackupTimeValue     *BackupTime    `json:"backupTime,omitempty" argument:"ignore"`
}

func (*Update) Validate

func (u *Update) Validate() error

type UpdateNotification

type UpdateNotification struct {
	DestinationId      string `json:"-" URIParam:"yes" valid:"required"`
	SubscriptionId     string `json:"-" URIParam:"yes" valid:"required"`
	DestinationRequest `argument:"composed"`
}

func (*UpdateNotification) Validate

func (c *UpdateNotification) Validate() error

type User

type User struct {
	Name     string `json:"name"`
	Password string `json:"password"`
}

type VerifyDestination

type VerifyDestination struct {
	DestinationId  string `json:"-" URIParam:"yes" valid:"required"`
	SubscriptionId string `json:"-" URIParam:"yes" valid:"required"`
	Token          string `json:"-" URIParam:"yes" valid:"required"`
}

Jump to

Keyboard shortcuts

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