Documentation ¶
Overview ¶
Package sqladmin provides access to the Cloud SQL Administration API.
See https://developers.google.com/cloud-sql/docs/admin-api/
Usage example:
import "camlistore.org/third_party/code.google.com/p/google-api-go-client/sqladmin/v1beta3" ... sqladminService, err := sqladmin.New(oauthHttpClient)
Index ¶
- Constants
- type BackupConfiguration
- type BackupRun
- type BackupRunsGetCall
- type BackupRunsListCall
- type BackupRunsListResponse
- type BackupRunsService
- type BinLogCoordinates
- type CloneContext
- type DatabaseFlags
- type DatabaseInstance
- type ExportContext
- type Flag
- type FlagsListCall
- type FlagsListResponse
- type FlagsService
- type ImportContext
- type InstanceOperation
- type InstanceSetRootPasswordRequest
- type InstancesCloneCall
- type InstancesCloneRequest
- type InstancesCloneResponse
- type InstancesDeleteCall
- type InstancesDeleteResponse
- type InstancesExportCall
- type InstancesExportRequest
- type InstancesExportResponse
- type InstancesGetCall
- type InstancesImportCall
- type InstancesImportRequest
- type InstancesImportResponse
- type InstancesInsertCall
- type InstancesInsertResponse
- type InstancesListCall
- type InstancesListResponse
- type InstancesPatchCall
- type InstancesResetSslConfigCall
- type InstancesResetSslConfigResponse
- type InstancesRestartCall
- type InstancesRestartResponse
- type InstancesRestoreBackupCall
- type InstancesRestoreBackupResponse
- type InstancesService
- func (r *InstancesService) Clone(project string, instancesclonerequest *InstancesCloneRequest) *InstancesCloneCall
- func (r *InstancesService) Delete(project string, instance string) *InstancesDeleteCall
- func (r *InstancesService) Export(project string, instance string, ...) *InstancesExportCall
- func (r *InstancesService) Get(project string, instance string) *InstancesGetCall
- func (r *InstancesService) Import(project string, instance string, ...) *InstancesImportCall
- func (r *InstancesService) Insert(project string, databaseinstance *DatabaseInstance) *InstancesInsertCall
- func (r *InstancesService) List(project string) *InstancesListCall
- func (r *InstancesService) Patch(project string, instance string, databaseinstance *DatabaseInstance) *InstancesPatchCall
- func (r *InstancesService) ResetSslConfig(project string, instance string) *InstancesResetSslConfigCall
- func (r *InstancesService) Restart(project string, instance string) *InstancesRestartCall
- func (r *InstancesService) RestoreBackup(project string, instance string, backupConfigurationid string, dueTime string) *InstancesRestoreBackupCall
- func (r *InstancesService) SetRootPassword(project string, instance string, ...) *InstancesSetRootPasswordCall
- func (r *InstancesService) Update(project string, instance string, databaseinstance *DatabaseInstance) *InstancesUpdateCall
- type InstancesSetRootPasswordCall
- type InstancesSetRootPasswordResponse
- type InstancesUpdateCall
- type InstancesUpdateResponse
- type IpConfiguration
- type IpMapping
- type LocationPreference
- type OperationError
- type OperationsGetCall
- type OperationsListCall
- type OperationsListResponse
- type OperationsService
- type Service
- type SetRootPasswordContext
- type Settings
- type SslCert
- type SslCertDetail
- type SslCertsDeleteCall
- type SslCertsDeleteResponse
- type SslCertsGetCall
- type SslCertsInsertCall
- type SslCertsInsertRequest
- type SslCertsInsertResponse
- type SslCertsListCall
- type SslCertsListResponse
- type SslCertsService
- func (r *SslCertsService) Delete(project string, instance string, sha1Fingerprint string) *SslCertsDeleteCall
- func (r *SslCertsService) Get(project string, instance string, sha1Fingerprint string) *SslCertsGetCall
- func (r *SslCertsService) Insert(project string, instance string, sslcertsinsertrequest *SslCertsInsertRequest) *SslCertsInsertCall
- func (r *SslCertsService) List(project string, instance string) *SslCertsListCall
- type Tier
- type TiersListCall
- type TiersListResponse
- type TiersService
Constants ¶
const ( // View and manage your data across Google Cloud Platform services CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" // Manage your Google SQL Service instances SqlserviceAdminScope = "https://www.googleapis.com/auth/sqlservice.admin" )
OAuth2 scopes used by this API.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BackupConfiguration ¶
type BackupConfiguration struct { // BinaryLogEnabled: Whether binary log is enabled. If backup // configuration is disabled, binary log must be disabled as well. BinaryLogEnabled bool `json:"binaryLogEnabled,omitempty"` // Enabled: Whether this configuration is enabled. Enabled bool `json:"enabled,omitempty"` // Id: Identifier for this configuration. This gets generated // automatically when a backup configuration is created. Id string `json:"id,omitempty"` // Kind: This is always sql#backupConfiguration. Kind string `json:"kind,omitempty"` // StartTime: Start time for the daily backup configuration in UTC // timezone in the 24 hour format - HH:MM. StartTime string `json:"startTime,omitempty"` }
type BackupRun ¶
type BackupRun struct { // BackupConfiguration: Backup Configuration identifier. BackupConfiguration string `json:"backupConfiguration,omitempty"` // DueTime: The due time of this run in UTC timezone in RFC 3339 format, // for example 2012-11-15T16:19:00.094Z. DueTime string `json:"dueTime,omitempty"` // EndTime: The time the backup operation completed in UTC timezone in // RFC 3339 format, for example 2012-11-15T16:19:00.094Z. EndTime string `json:"endTime,omitempty"` // EnqueuedTime: The time the run was enqueued in UTC timezone in RFC // 3339 format, for example 2012-11-15T16:19:00.094Z. EnqueuedTime string `json:"enqueuedTime,omitempty"` // Error: Information about why the backup operation failed. This is // only present if the run has the FAILED status. Error *OperationError `json:"error,omitempty"` // Instance: Name of the database instance. Instance string `json:"instance,omitempty"` // Kind: This is always sql#backupRun. Kind string `json:"kind,omitempty"` // StartTime: The time the backup operation actually started in UTC // timezone in RFC 3339 format, for example 2012-11-15T16:19:00.094Z. StartTime string `json:"startTime,omitempty"` // Status: The status of this run. Status string `json:"status,omitempty"` }
type BackupRunsGetCall ¶
type BackupRunsGetCall struct {
// contains filtered or unexported fields
}
func (*BackupRunsGetCall) Do ¶
func (c *BackupRunsGetCall) Do() (*BackupRun, error)
type BackupRunsListCall ¶
type BackupRunsListCall struct {
// contains filtered or unexported fields
}
func (*BackupRunsListCall) Do ¶
func (c *BackupRunsListCall) Do() (*BackupRunsListResponse, error)
func (*BackupRunsListCall) MaxResults ¶
func (c *BackupRunsListCall) MaxResults(maxResults int64) *BackupRunsListCall
MaxResults sets the optional parameter "maxResults": Maximum number of backup runs per response.
func (*BackupRunsListCall) PageToken ¶
func (c *BackupRunsListCall) PageToken(pageToken string) *BackupRunsListCall
PageToken sets the optional parameter "pageToken": A previously-returned page token representing part of the larger set of results to view.
type BackupRunsListResponse ¶
type BackupRunsListResponse struct { // Items: A list of backup runs in reverse chronological order of the // enqueued time. Items []*BackupRun `json:"items,omitempty"` // Kind: This is always sql#backupRunsList. Kind string `json:"kind,omitempty"` // NextPageToken: The continuation token, used to page through large // result sets. Provide this value in a subsequent request to return the // next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type BackupRunsService ¶
type BackupRunsService struct {
// contains filtered or unexported fields
}
func NewBackupRunsService ¶
func NewBackupRunsService(s *Service) *BackupRunsService
func (*BackupRunsService) Get ¶
func (r *BackupRunsService) Get(project string, instance string, backupConfiguration string, dueTime string) *BackupRunsGetCall
Get: Retrieves a resource containing information about a backup run.
func (*BackupRunsService) List ¶
func (r *BackupRunsService) List(project string, instance string, backupConfiguration string) *BackupRunsListCall
List: Lists all backup runs associated with a given instance and configuration in the reverse chronological order of the enqueued time.
type BinLogCoordinates ¶
type BinLogCoordinates struct { // BinLogFileName: Name of the binary log file for a Cloud SQL instance. BinLogFileName string `json:"binLogFileName,omitempty"` // BinLogPosition: Position (offset) within the binary log file. BinLogPosition int64 `json:"binLogPosition,omitempty,string"` // Kind: This is always sql#binLogCoordinates. Kind string `json:"kind,omitempty"` }
type CloneContext ¶
type CloneContext struct { // BinLogCoordinates: Binary log coordinates, if specified, indentify // the the position up to which the source instance should be cloned. If // not specified, the source instance is cloned up to the most recent // binary log coordintes. BinLogCoordinates *BinLogCoordinates `json:"binLogCoordinates,omitempty"` // DestinationInstanceName: Name of the Cloud SQL instance to be created // as a clone. DestinationInstanceName string `json:"destinationInstanceName,omitempty"` // Kind: This is always sql#cloneContext. Kind string `json:"kind,omitempty"` // SourceInstanceName: Name of the Cloud SQL instance to be cloned. SourceInstanceName string `json:"sourceInstanceName,omitempty"` }
type DatabaseFlags ¶
type DatabaseFlags struct { // Name: The name of the flag. These flags are passed at instance // startup, so include both MySQL server options and MySQL system // variables. Flags should be specified with underscores, not hyphens. // Refer to the official MySQL documentation on server options and // system variables for descriptions of what these flags do. Acceptable // values are: event_scheduler on or off (Note: The event scheduler // will only work reliably if the instance activationPolicy is set to // ALWAYS.) general_log on or off group_concat_max_len 4..17179869184 // innodb_flush_log_at_trx_commit 0..2 innodb_lock_wait_timeout // 1..1073741824 log_bin_trust_function_creators on or off log_output // Can be either TABLE or NONE, FILE is not supported. // log_queries_not_using_indexes on or off long_query_time 0..30000000 // lower_case_table_names 0..2 max_allowed_packet 16384..1073741824 // read_only on or off skip_show_database on or off slow_query_log on or // off wait_timeout 1..31536000 Name string `json:"name,omitempty"` // Value: The value of the flag. Booleans should be set using 1 for // true, and 0 for false. This field must be omitted if the flag doesn't // take a value. Value string `json:"value,omitempty"` }
type DatabaseInstance ¶
type DatabaseInstance struct { // CurrentDiskSize: The current disk usage of the instance in bytes. CurrentDiskSize int64 `json:"currentDiskSize,omitempty,string"` // DatabaseVersion: The database engine type and version. Can be // MYSQL_5_5 or MYSQL_5_6. Defaults to MYSQL_5_5. The databaseVersion // can not be changed after instance creation. DatabaseVersion string `json:"databaseVersion,omitempty"` // Etag: HTTP 1.1 Entity tag for the resource. Etag string `json:"etag,omitempty"` // Instance: Name of the Cloud SQL instance. This does not include the // project ID. Instance string `json:"instance,omitempty"` // IpAddresses: The assigned IP addresses for the instance. IpAddresses []*IpMapping `json:"ipAddresses,omitempty"` // Kind: This is always sql#instance. Kind string `json:"kind,omitempty"` // MaxDiskSize: The maximum disk size of the instance in bytes. MaxDiskSize int64 `json:"maxDiskSize,omitempty,string"` // Project: The project ID of the project containing the Cloud SQL // instance. The Google apps domain is prefixed if applicable. Project string `json:"project,omitempty"` // Region: The geographical region. Can be us-east1, us-central, // asia-east1 or europe-west1. Defaults to us-central. The region can // not be changed after instance creation. Region string `json:"region,omitempty"` // ServerCaCert: SSL configuration. ServerCaCert *SslCert `json:"serverCaCert,omitempty"` // Settings: The user settings. Settings *Settings `json:"settings,omitempty"` // State: The current serving state of the Cloud SQL instance. This can // be one of the following. // RUNNABLE: The instance is running, or is // ready to run when accessed. // SUSPENDED: The instance is not available, // for example due to problems with billing. // PENDING_CREATE: The // instance is being created. // MAINTENANCE: The instance is down for // maintenance. // UNKNOWN_STATE: The state of the instance is unknown. State string `json:"state,omitempty"` }
type ExportContext ¶
type ExportContext struct { // Database: Databases (for example, guestbook) from which the export is // made. If unspecified, all databases are exported. Database []string `json:"database,omitempty"` // Kind: This is always sql#exportContext. Kind string `json:"kind,omitempty"` // Table: Tables to export, or that were exported, from the specified // database. If you specify tables, specify one and only one database. Table []string `json:"table,omitempty"` // Uri: The path to the file in Google Cloud Storage where the export // will be stored, or where it was already stored. The URI is in the // form gs://bucketName/fileName. If the file already exists, the // operation fails. If the filename ends with .gz, the contents are // compressed. Uri string `json:"uri,omitempty"` }
type Flag ¶
type Flag struct { // AllowedStringValues: For STRING flags, a list of strings that the // value can be set to. AllowedStringValues []string `json:"allowedStringValues,omitempty"` // AppliesTo: The database version this flag applies to. Currently this // can only be [MYSQL_5_5]. AppliesTo []string `json:"appliesTo,omitempty"` // Kind: This is always sql#flag. Kind string `json:"kind,omitempty"` // MaxValue: For INTEGER flags, the maximum allowed value. MaxValue int64 `json:"maxValue,omitempty,string"` // MinValue: For INTEGER flags, the minimum allowed value. MinValue int64 `json:"minValue,omitempty,string"` // Name: This is the name of the flag. Flag names always use // underscores, not hyphens, e.g. max_allowed_packet Name string `json:"name,omitempty"` // Type: The type of the flag. Flags are typed to being BOOLEAN, STRING, // INTEGER or NONE. NONE is used for flags which do not take a value, // such as skip_grant_tables. Type string `json:"type,omitempty"` }
type FlagsListCall ¶
type FlagsListCall struct {
// contains filtered or unexported fields
}
func (*FlagsListCall) Do ¶
func (c *FlagsListCall) Do() (*FlagsListResponse, error)
type FlagsListResponse ¶
type FlagsService ¶
type FlagsService struct {
// contains filtered or unexported fields
}
func NewFlagsService ¶
func NewFlagsService(s *Service) *FlagsService
func (*FlagsService) List ¶
func (r *FlagsService) List() *FlagsListCall
List: List all available database flags for Google Cloud SQL instances.
type ImportContext ¶
type ImportContext struct { // Database: The database (for example, guestbook) to which the import // is made. If not set, it is assumed that the database is specified in // the file to be imported. Database string `json:"database,omitempty"` // Kind: This is always sql#importContext. Kind string `json:"kind,omitempty"` // Uri: A path to the MySQL dump file in Google Cloud Storage from which // the import is made. The URI is in the form gs://bucketName/fileName. // Compressed gzip files (.gz) are also supported. Uri []string `json:"uri,omitempty"` }
type InstanceOperation ¶
type InstanceOperation struct { // EndTime: The time this operation finished in UTC timezone in RFC 3339 // format, for example 2012-11-15T16:19:00.094Z. EndTime string `json:"endTime,omitempty"` // EnqueuedTime: The time this operation was enqueued in UTC timezone in // RFC 3339 format, for example 2012-11-15T16:19:00.094Z. EnqueuedTime string `json:"enqueuedTime,omitempty"` // Error: The error(s) encountered by this operation. Only set if the // operation results in an error. Error []*OperationError `json:"error,omitempty"` // ExportContext: The context for export operation, if applicable. ExportContext *ExportContext `json:"exportContext,omitempty"` // ImportContext: The context for import operation, if applicable. ImportContext *ImportContext `json:"importContext,omitempty"` // Instance: Name of the database instance. Instance string `json:"instance,omitempty"` // Kind: This is always sql#instanceOperation. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` // OperationType: The type of the operation. Valid values are CREATE, // DELETE, UPDATE, RESTART, IMPORT, EXPORT, BACKUP_VOLUME, // RESTORE_VOLUME. OperationType string `json:"operationType,omitempty"` // StartTime: The time this operation actually started in UTC timezone // in RFC 3339 format, for example 2012-11-15T16:19:00.094Z. StartTime string `json:"startTime,omitempty"` // State: The state of an operation. Valid values are PENDING, RUNNING, // DONE, UNKNOWN. State string `json:"state,omitempty"` // UserEmailAddress: The email address of the user who initiated this // operation. UserEmailAddress string `json:"userEmailAddress,omitempty"` }
type InstanceSetRootPasswordRequest ¶
type InstanceSetRootPasswordRequest struct { // SetRootPasswordContext: Set Root Password Context. SetRootPasswordContext *SetRootPasswordContext `json:"setRootPasswordContext,omitempty"` }
type InstancesCloneCall ¶
type InstancesCloneCall struct {
// contains filtered or unexported fields
}
func (*InstancesCloneCall) Do ¶
func (c *InstancesCloneCall) Do() (*InstancesCloneResponse, error)
type InstancesCloneRequest ¶
type InstancesCloneRequest struct { // CloneContext: Contains details about the clone operation. CloneContext *CloneContext `json:"cloneContext,omitempty"` }
type InstancesCloneResponse ¶
type InstancesCloneResponse struct { // Kind: This is always sql#instancesClone. Kind string `json:"kind,omitempty"` // Operation: An unique identifier for the operation associated with the // cloned instance. You can use this identifier to retrieve the // Operations resource, which has information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesDeleteCall ¶
type InstancesDeleteCall struct {
// contains filtered or unexported fields
}
func (*InstancesDeleteCall) Do ¶
func (c *InstancesDeleteCall) Do() (*InstancesDeleteResponse, error)
type InstancesDeleteResponse ¶
type InstancesDeleteResponse struct { // Kind: This is always sql#instancesDelete. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesExportCall ¶
type InstancesExportCall struct {
// contains filtered or unexported fields
}
func (*InstancesExportCall) Do ¶
func (c *InstancesExportCall) Do() (*InstancesExportResponse, error)
type InstancesExportRequest ¶
type InstancesExportRequest struct { // ExportContext: Contains details about the export operation. ExportContext *ExportContext `json:"exportContext,omitempty"` }
type InstancesExportResponse ¶
type InstancesExportResponse struct { // Kind: This is always sql#instancesExport. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesGetCall ¶
type InstancesGetCall struct {
// contains filtered or unexported fields
}
func (*InstancesGetCall) Do ¶
func (c *InstancesGetCall) Do() (*DatabaseInstance, error)
type InstancesImportCall ¶
type InstancesImportCall struct {
// contains filtered or unexported fields
}
func (*InstancesImportCall) Do ¶
func (c *InstancesImportCall) Do() (*InstancesImportResponse, error)
type InstancesImportRequest ¶
type InstancesImportRequest struct { // ImportContext: Contains details about the import operation. ImportContext *ImportContext `json:"importContext,omitempty"` }
type InstancesImportResponse ¶
type InstancesImportResponse struct { // Kind: This is always sql#instancesImport. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesInsertCall ¶
type InstancesInsertCall struct {
// contains filtered or unexported fields
}
func (*InstancesInsertCall) Do ¶
func (c *InstancesInsertCall) Do() (*InstancesInsertResponse, error)
type InstancesInsertResponse ¶
type InstancesInsertResponse struct { // Kind: This is always sql#instancesInsert. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesListCall ¶
type InstancesListCall struct {
// contains filtered or unexported fields
}
func (*InstancesListCall) Do ¶
func (c *InstancesListCall) Do() (*InstancesListResponse, error)
func (*InstancesListCall) MaxResults ¶
func (c *InstancesListCall) MaxResults(maxResults int64) *InstancesListCall
MaxResults sets the optional parameter "maxResults": The maximum number of results to return per response.
func (*InstancesListCall) PageToken ¶
func (c *InstancesListCall) PageToken(pageToken string) *InstancesListCall
PageToken sets the optional parameter "pageToken": A previously-returned page token representing part of the larger set of results to view.
type InstancesListResponse ¶
type InstancesListResponse struct { // Items: List of database instance resources. Items []*DatabaseInstance `json:"items,omitempty"` // Kind: This is always sql#instancesList. Kind string `json:"kind,omitempty"` // NextPageToken: The continuation token, used to page through large // result sets. Provide this value in a subsequent request to return the // next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type InstancesPatchCall ¶
type InstancesPatchCall struct {
// contains filtered or unexported fields
}
func (*InstancesPatchCall) Do ¶
func (c *InstancesPatchCall) Do() (*InstancesUpdateResponse, error)
type InstancesResetSslConfigCall ¶
type InstancesResetSslConfigCall struct {
// contains filtered or unexported fields
}
func (*InstancesResetSslConfigCall) Do ¶
func (c *InstancesResetSslConfigCall) Do() (*InstancesResetSslConfigResponse, error)
type InstancesResetSslConfigResponse ¶
type InstancesResetSslConfigResponse struct { // Kind: This is always sql#instancesResetSslConfig. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. All ssl client certificates will be // deleted and a new server certificate will be created. Does not take // effect until the next instance restart. Operation string `json:"operation,omitempty"` }
type InstancesRestartCall ¶
type InstancesRestartCall struct {
// contains filtered or unexported fields
}
func (*InstancesRestartCall) Do ¶
func (c *InstancesRestartCall) Do() (*InstancesRestartResponse, error)
type InstancesRestartResponse ¶
type InstancesRestartResponse struct { // Kind: This is always sql#instancesRestart. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesRestoreBackupCall ¶
type InstancesRestoreBackupCall struct {
// contains filtered or unexported fields
}
func (*InstancesRestoreBackupCall) Do ¶
func (c *InstancesRestoreBackupCall) Do() (*InstancesRestoreBackupResponse, error)
type InstancesRestoreBackupResponse ¶
type InstancesRestoreBackupResponse struct { // Kind: This is always sql#instancesRestoreBackup. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesService ¶
type InstancesService struct {
// contains filtered or unexported fields
}
func NewInstancesService ¶
func NewInstancesService(s *Service) *InstancesService
func (*InstancesService) Clone ¶
func (r *InstancesService) Clone(project string, instancesclonerequest *InstancesCloneRequest) *InstancesCloneCall
Clone: Creates a Cloud SQL instance as a clone of the source instance.
func (*InstancesService) Delete ¶
func (r *InstancesService) Delete(project string, instance string) *InstancesDeleteCall
Delete: Deletes a Cloud SQL instance.
func (*InstancesService) Export ¶
func (r *InstancesService) Export(project string, instance string, instancesexportrequest *InstancesExportRequest) *InstancesExportCall
Export: Exports data from a Cloud SQL instance to a Google Cloud Storage bucket as a MySQL dump file.
func (*InstancesService) Get ¶
func (r *InstancesService) Get(project string, instance string) *InstancesGetCall
Get: Retrieves a resource containing information about a Cloud SQL instance.
func (*InstancesService) Import ¶
func (r *InstancesService) Import(project string, instance string, instancesimportrequest *InstancesImportRequest) *InstancesImportCall
Import: Imports data into a Cloud SQL instance from a MySQL dump file in Google Cloud Storage.
func (*InstancesService) Insert ¶
func (r *InstancesService) Insert(project string, databaseinstance *DatabaseInstance) *InstancesInsertCall
Insert: Creates a new Cloud SQL instance.
func (*InstancesService) List ¶
func (r *InstancesService) List(project string) *InstancesListCall
List: Lists instances under a given project in the alphabetical order of the instance name.
func (*InstancesService) Patch ¶
func (r *InstancesService) Patch(project string, instance string, databaseinstance *DatabaseInstance) *InstancesPatchCall
Patch: Updates settings of a Cloud SQL instance. Caution: This is not a partial update, so you must include values for all the settings that you want to retain. For partial updates, use patch.. This method supports patch semantics.
func (*InstancesService) ResetSslConfig ¶
func (r *InstancesService) ResetSslConfig(project string, instance string) *InstancesResetSslConfigCall
ResetSslConfig: Deletes all client certificates and generates a new server SSL certificate for the instance. The changes will not take effect until the instance is restarted. Existing instances without a server certificate will need to call this once to set a server certificate.
func (*InstancesService) Restart ¶
func (r *InstancesService) Restart(project string, instance string) *InstancesRestartCall
Restart: Restarts a Cloud SQL instance.
func (*InstancesService) RestoreBackup ¶
func (r *InstancesService) RestoreBackup(project string, instance string, backupConfigurationid string, dueTime string) *InstancesRestoreBackupCall
RestoreBackup: Restores a backup of a Cloud SQL instance.
func (*InstancesService) SetRootPassword ¶
func (r *InstancesService) SetRootPassword(project string, instance string, instancesetrootpasswordrequest *InstanceSetRootPasswordRequest) *InstancesSetRootPasswordCall
SetRootPassword: Sets the password for the root user.
func (*InstancesService) Update ¶
func (r *InstancesService) Update(project string, instance string, databaseinstance *DatabaseInstance) *InstancesUpdateCall
Update: Updates settings of a Cloud SQL instance. Caution: This is not a partial update, so you must include values for all the settings that you want to retain. For partial updates, use patch.
type InstancesSetRootPasswordCall ¶
type InstancesSetRootPasswordCall struct {
// contains filtered or unexported fields
}
func (*InstancesSetRootPasswordCall) Do ¶
func (c *InstancesSetRootPasswordCall) Do() (*InstancesSetRootPasswordResponse, error)
type InstancesSetRootPasswordResponse ¶
type InstancesSetRootPasswordResponse struct { // Kind: This is always sql#instancesSetRootPassword. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type InstancesUpdateCall ¶
type InstancesUpdateCall struct {
// contains filtered or unexported fields
}
func (*InstancesUpdateCall) Do ¶
func (c *InstancesUpdateCall) Do() (*InstancesUpdateResponse, error)
type InstancesUpdateResponse ¶
type InstancesUpdateResponse struct { // Kind: This is always sql#instancesUpdate. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve information about the operation. Operation string `json:"operation,omitempty"` }
type IpConfiguration ¶
type IpConfiguration struct { // AuthorizedNetworks: The list of external networks that are allowed to // connect to the instance using the IP. In CIDR notation, also known as // 'slash' notation (e.g. 192.168.100.0/24). AuthorizedNetworks []string `json:"authorizedNetworks,omitempty"` // Enabled: Whether the instance should be assigned an IP address or // not. Enabled bool `json:"enabled,omitempty"` // RequireSsl: Whether the mysqld should default to 'REQUIRE X509' for // users connecting over IP. RequireSsl bool `json:"requireSsl,omitempty"` }
type IpMapping ¶
type IpMapping struct { // IpAddress: The IP address assigned. IpAddress string `json:"ipAddress,omitempty"` // TimeToRetire: The due time for this IP to be retired in RFC 3339 // format, for example 2012-11-15T16:19:00.094Z. This field is only // available when the IP is scheduled to be retired. TimeToRetire string `json:"timeToRetire,omitempty"` }
type LocationPreference ¶
type LocationPreference struct { // FollowGaeApplication: The AppEngine application to follow, it must be // in the same region as the Cloud SQL instance. FollowGaeApplication string `json:"followGaeApplication,omitempty"` // Kind: This is always sql#locationPreference. Kind string `json:"kind,omitempty"` // Zone: The preferred Compute Engine zone (e.g. us-centra1-a, // us-central1-b, etc.). Zone string `json:"zone,omitempty"` }
type OperationError ¶
type OperationsGetCall ¶
type OperationsGetCall struct {
// contains filtered or unexported fields
}
func (*OperationsGetCall) Do ¶
func (c *OperationsGetCall) Do() (*InstanceOperation, error)
type OperationsListCall ¶
type OperationsListCall struct {
// contains filtered or unexported fields
}
func (*OperationsListCall) Do ¶
func (c *OperationsListCall) Do() (*OperationsListResponse, error)
func (*OperationsListCall) MaxResults ¶
func (c *OperationsListCall) MaxResults(maxResults int64) *OperationsListCall
MaxResults sets the optional parameter "maxResults": Maximum number of operations per response.
func (*OperationsListCall) PageToken ¶
func (c *OperationsListCall) PageToken(pageToken string) *OperationsListCall
PageToken sets the optional parameter "pageToken": A previously-returned page token representing part of the larger set of results to view.
type OperationsListResponse ¶
type OperationsListResponse struct { // Items: List of operation resources. Items []*InstanceOperation `json:"items,omitempty"` // Kind: This is always sql#operationsList. Kind string `json:"kind,omitempty"` // NextPageToken: The continuation token, used to page through large // result sets. Provide this value in a subsequent request to return the // next page of results. NextPageToken string `json:"nextPageToken,omitempty"` }
type OperationsService ¶
type OperationsService struct {
// contains filtered or unexported fields
}
func NewOperationsService ¶
func NewOperationsService(s *Service) *OperationsService
func (*OperationsService) Get ¶
func (r *OperationsService) Get(project string, instance string, operation string) *OperationsGetCall
Get: Retrieves an instance operation that has been performed on an instance.
func (*OperationsService) List ¶
func (r *OperationsService) List(project string, instance string) *OperationsListCall
List: Lists all instance operations that have been performed on the given Cloud SQL instance in the reverse chronological order of the start time.
type Service ¶
type Service struct { BasePath string // API endpoint base URL BackupRuns *BackupRunsService Flags *FlagsService Instances *InstancesService Operations *OperationsService SslCerts *SslCertsService Tiers *TiersService // contains filtered or unexported fields }
type SetRootPasswordContext ¶
type Settings ¶
type Settings struct { // ActivationPolicy: The activation policy for this instance. This // specifies when the instance should be activated and is applicable // only when the instance state is RUNNABLE. This can be one of the // following. // ALWAYS: The instance should always be active. // NEVER: The // instance should never be activated. // ON_DEMAND: The instance is // activated upon receiving requests. ActivationPolicy string `json:"activationPolicy,omitempty"` // AuthorizedGaeApplications: The AppEngine app ids that can access this // instance. AuthorizedGaeApplications []string `json:"authorizedGaeApplications,omitempty"` // BackupConfiguration: The daily backup configuration for the instance. BackupConfiguration []*BackupConfiguration `json:"backupConfiguration,omitempty"` // DatabaseFlags: The database flags passed to the instance at startup. DatabaseFlags []*DatabaseFlags `json:"databaseFlags,omitempty"` // IpConfiguration: The settings for IP Management. This allows to // enable or disable the instance IP and manage which external networks // can connect to the instance. IpConfiguration *IpConfiguration `json:"ipConfiguration,omitempty"` // Kind: This is always sql#settings. Kind string `json:"kind,omitempty"` // LocationPreference: The location preference settings. This allows the // instance to be located as near as possible to either an AppEngine app // or GCE zone for better perfomance. LocationPreference *LocationPreference `json:"locationPreference,omitempty"` // PricingPlan: The pricing plan for this instance. This can be either // PER_USE or PACKAGE. PricingPlan string `json:"pricingPlan,omitempty"` // ReplicationType: The type of replication this instance uses. This can // be either ASYNCHRONOUS or SYNCHRONOUS. ReplicationType string `json:"replicationType,omitempty"` // SettingsVersion: The version of instance settings. This is a required // field for update method to make sure concurrent updates are handled // properly. During update, use the most recent settingsVersion value // for this instance and do not try to update this value. SettingsVersion int64 `json:"settingsVersion,omitempty,string"` // Tier: The tier of service for this instance, for example D1, D2. For // more information, see pricing. Tier string `json:"tier,omitempty"` }
type SslCert ¶
type SslCert struct { // Cert: PEM representation. Cert string `json:"cert,omitempty"` // CertSerialNumber: Serial number, as extracted from the certificate. CertSerialNumber string `json:"certSerialNumber,omitempty"` // CommonName: User supplied name. Constrained to [a-zA-Z.-_ ]+. CommonName string `json:"commonName,omitempty"` // CreateTime: Time when the certificate was created. CreateTime string `json:"createTime,omitempty"` // ExpirationTime: Time when the certificate expires. ExpirationTime string `json:"expirationTime,omitempty"` // Instance: Name of the database instance. Instance string `json:"instance,omitempty"` // Kind: This is always sql#sslCert. Kind string `json:"kind,omitempty"` // Sha1Fingerprint: Sha1 Fingerprint. Sha1Fingerprint string `json:"sha1Fingerprint,omitempty"` }
type SslCertDetail ¶
type SslCertDetail struct { // CertInfo: The public information about the cert. CertInfo *SslCert `json:"certInfo,omitempty"` // CertPrivateKey: The private key for the client cert, in pem format. // Keep private in order to protect your security. CertPrivateKey string `json:"certPrivateKey,omitempty"` }
type SslCertsDeleteCall ¶
type SslCertsDeleteCall struct {
// contains filtered or unexported fields
}
func (*SslCertsDeleteCall) Do ¶
func (c *SslCertsDeleteCall) Do() (*SslCertsDeleteResponse, error)
type SslCertsDeleteResponse ¶
type SslCertsDeleteResponse struct { // Kind: This is always sql#sslCertsDelete. Kind string `json:"kind,omitempty"` // Operation: An identifier that uniquely identifies the operation. You // can use this identifier to retrieve the Operations resource that has // information about the operation. Operation string `json:"operation,omitempty"` }
type SslCertsGetCall ¶
type SslCertsGetCall struct {
// contains filtered or unexported fields
}
func (*SslCertsGetCall) Do ¶
func (c *SslCertsGetCall) Do() (*SslCert, error)
type SslCertsInsertCall ¶
type SslCertsInsertCall struct {
// contains filtered or unexported fields
}
func (*SslCertsInsertCall) Do ¶
func (c *SslCertsInsertCall) Do() (*SslCertsInsertResponse, error)
type SslCertsInsertRequest ¶
type SslCertsInsertRequest struct { // CommonName: User supplied name. Must be a distinct name from the // other certificates for this instance. New certificates will not be // usable until the instance is restarted. CommonName string `json:"commonName,omitempty"` }
type SslCertsInsertResponse ¶
type SslCertsInsertResponse struct { // ClientCert: The new client certificate and private key. The new // certificate will not work until the instance is restarted. ClientCert *SslCertDetail `json:"clientCert,omitempty"` // Kind: This is always sql#sslCertsInsert. Kind string `json:"kind,omitempty"` // ServerCaCert: The server Certificate Authority's certificate. If this // is missing you can force a new one to be generated by calling // resetSslConfig method on instances resource.. ServerCaCert *SslCert `json:"serverCaCert,omitempty"` }
type SslCertsListCall ¶
type SslCertsListCall struct {
// contains filtered or unexported fields
}
func (*SslCertsListCall) Do ¶
func (c *SslCertsListCall) Do() (*SslCertsListResponse, error)
type SslCertsListResponse ¶
type SslCertsService ¶
type SslCertsService struct {
// contains filtered or unexported fields
}
func NewSslCertsService ¶
func NewSslCertsService(s *Service) *SslCertsService
func (*SslCertsService) Delete ¶
func (r *SslCertsService) Delete(project string, instance string, sha1Fingerprint string) *SslCertsDeleteCall
Delete: Deletes the SSL certificate. The change will not take effect until the instance is restarted.
func (*SslCertsService) Get ¶
func (r *SslCertsService) Get(project string, instance string, sha1Fingerprint string) *SslCertsGetCall
Get: Retrieves a particular SSL certificate. Does not include the private key (required for usage). The private key must be saved from the response to initial creation.
func (*SslCertsService) Insert ¶
func (r *SslCertsService) Insert(project string, instance string, sslcertsinsertrequest *SslCertsInsertRequest) *SslCertsInsertCall
Insert: Creates an SSL certificate and returns it along with the private key and server certificate authority. The new certificate will not be usable until the instance is restarted.
func (*SslCertsService) List ¶
func (r *SslCertsService) List(project string, instance string) *SslCertsListCall
List: Lists all of the current SSL certificates for the instance.
type Tier ¶
type Tier struct { // DiskQuota: The maximum disk size of this tier in bytes. DiskQuota int64 `json:"DiskQuota,omitempty,string"` // RAM: The maximum RAM usage of this tier in bytes. RAM int64 `json:"RAM,omitempty,string"` // Kind: This is always sql#tier. Kind string `json:"kind,omitempty"` // Region: The applicable regions for this tier. Can be us-east1, // europe-west1, or asia-east1. Region []string `json:"region,omitempty"` // Tier: An identifier for the service tier, for example D1, D2 etc. For // related information, see Pricing. Tier string `json:"tier,omitempty"` }
type TiersListCall ¶
type TiersListCall struct {
// contains filtered or unexported fields
}
func (*TiersListCall) Do ¶
func (c *TiersListCall) Do() (*TiersListResponse, error)
type TiersListResponse ¶
type TiersService ¶
type TiersService struct {
// contains filtered or unexported fields
}
func NewTiersService ¶
func NewTiersService(s *Service) *TiersService
func (*TiersService) List ¶
func (r *TiersService) List(project string) *TiersListCall
List: Lists all available service tiers for Google Cloud SQL, for example D1, D2. For related information, see Pricing.