sqladmin
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Overview¶
Package sqladmin provides access to the Cloud SQL Admin API.
For product documentation, see:https://cloud.google.com/sql/docs
Library status¶
These client libraries are officially supported by Google. However, thislibrary is considered complete and is in maintenance mode. This meansthat we will address critical bugs and security issues but will not addany new features.
When possible, we recommend using our newer[Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go)that are still actively being worked and iterated on.
Creating a client¶
Usage example:
import "google.golang.org/api/sqladmin/v1"...ctx := context.Background()sqladminService, err := sqladmin.NewService(ctx)
In this example, Google Application Default Credentials are used forauthentication. For information on how to create and obtain ApplicationDefault Credentials, seehttps://developers.google.com/identity/protocols/application-default-credentials.
Other authentication options¶
By default, all available scopes (see "Constants") are used to authenticate.To restrict scopes, usegoogle.golang.org/api/option.WithScopes:
sqladminService, err := sqladmin.NewService(ctx, option.WithScopes(sqladmin.SqlserviceAdminScope))
To use an API key for authentication (note: some APIs do not support APIkeys), usegoogle.golang.org/api/option.WithAPIKey:
sqladminService, err := sqladmin.NewService(ctx, option.WithAPIKey("AIza..."))To use an OAuth token (e.g., a user token obtained via a three-legged OAuthflow, usegoogle.golang.org/api/option.WithTokenSource:
config := &oauth2.Config{...}// ...token, err := config.Exchange(ctx, ...)sqladminService, err := sqladmin.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))Seegoogle.golang.org/api/option.ClientOption for details on options.
Index¶
- Constants
- type AclEntry
- type AcquireSsrsLeaseContext
- type AdvancedMachineFeatures
- type ApiWarning
- type AvailableDatabaseVersion
- type Backup
- type BackupConfiguration
- type BackupContext
- type BackupReencryptionConfig
- type BackupRetentionSettings
- type BackupRun
- type BackupRunsDeleteCall
- type BackupRunsGetCall
- func (c *BackupRunsGetCall) Context(ctx context.Context) *BackupRunsGetCall
- func (c *BackupRunsGetCall) Do(opts ...googleapi.CallOption) (*BackupRun, error)
- func (c *BackupRunsGetCall) Fields(s ...googleapi.Field) *BackupRunsGetCall
- func (c *BackupRunsGetCall) Header() http.Header
- func (c *BackupRunsGetCall) IfNoneMatch(entityTag string) *BackupRunsGetCall
- type BackupRunsInsertCall
- type BackupRunsListCall
- func (c *BackupRunsListCall) Context(ctx context.Context) *BackupRunsListCall
- func (c *BackupRunsListCall) Do(opts ...googleapi.CallOption) (*BackupRunsListResponse, error)
- func (c *BackupRunsListCall) Fields(s ...googleapi.Field) *BackupRunsListCall
- func (c *BackupRunsListCall) Header() http.Header
- func (c *BackupRunsListCall) IfNoneMatch(entityTag string) *BackupRunsListCall
- func (c *BackupRunsListCall) MaxResults(maxResults int64) *BackupRunsListCall
- func (c *BackupRunsListCall) PageToken(pageToken string) *BackupRunsListCall
- func (c *BackupRunsListCall) Pages(ctx context.Context, f func(*BackupRunsListResponse) error) error
- type BackupRunsListResponse
- type BackupRunsService
- func (r *BackupRunsService) Delete(project string, instance string, id int64) *BackupRunsDeleteCall
- func (r *BackupRunsService) Get(project string, instance string, id int64) *BackupRunsGetCall
- func (r *BackupRunsService) Insert(project string, instance string, backuprun *BackupRun) *BackupRunsInsertCall
- func (r *BackupRunsService) List(project string, instance string) *BackupRunsListCall
- type BackupsCreateBackupCall
- func (c *BackupsCreateBackupCall) Context(ctx context.Context) *BackupsCreateBackupCall
- func (c *BackupsCreateBackupCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *BackupsCreateBackupCall) Fields(s ...googleapi.Field) *BackupsCreateBackupCall
- func (c *BackupsCreateBackupCall) Header() http.Header
- type BackupsDeleteBackupCall
- func (c *BackupsDeleteBackupCall) Context(ctx context.Context) *BackupsDeleteBackupCall
- func (c *BackupsDeleteBackupCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *BackupsDeleteBackupCall) Fields(s ...googleapi.Field) *BackupsDeleteBackupCall
- func (c *BackupsDeleteBackupCall) Header() http.Header
- type BackupsGetBackupCall
- func (c *BackupsGetBackupCall) Context(ctx context.Context) *BackupsGetBackupCall
- func (c *BackupsGetBackupCall) Do(opts ...googleapi.CallOption) (*Backup, error)
- func (c *BackupsGetBackupCall) Fields(s ...googleapi.Field) *BackupsGetBackupCall
- func (c *BackupsGetBackupCall) Header() http.Header
- func (c *BackupsGetBackupCall) IfNoneMatch(entityTag string) *BackupsGetBackupCall
- type BackupsListBackupsCall
- func (c *BackupsListBackupsCall) Context(ctx context.Context) *BackupsListBackupsCall
- func (c *BackupsListBackupsCall) Do(opts ...googleapi.CallOption) (*ListBackupsResponse, error)
- func (c *BackupsListBackupsCall) Fields(s ...googleapi.Field) *BackupsListBackupsCall
- func (c *BackupsListBackupsCall) Filter(filter string) *BackupsListBackupsCall
- func (c *BackupsListBackupsCall) Header() http.Header
- func (c *BackupsListBackupsCall) IfNoneMatch(entityTag string) *BackupsListBackupsCall
- func (c *BackupsListBackupsCall) PageSize(pageSize int64) *BackupsListBackupsCall
- func (c *BackupsListBackupsCall) PageToken(pageToken string) *BackupsListBackupsCall
- func (c *BackupsListBackupsCall) Pages(ctx context.Context, f func(*ListBackupsResponse) error) error
- type BackupsService
- func (r *BackupsService) CreateBackup(parent string, backup *Backup) *BackupsCreateBackupCall
- func (r *BackupsService) DeleteBackup(name string) *BackupsDeleteBackupCall
- func (r *BackupsService) GetBackup(name string) *BackupsGetBackupCall
- func (r *BackupsService) ListBackups(parent string) *BackupsListBackupsCall
- func (r *BackupsService) UpdateBackup(name string, backup *Backup) *BackupsUpdateBackupCall
- type BackupsUpdateBackupCall
- func (c *BackupsUpdateBackupCall) Context(ctx context.Context) *BackupsUpdateBackupCall
- func (c *BackupsUpdateBackupCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *BackupsUpdateBackupCall) Fields(s ...googleapi.Field) *BackupsUpdateBackupCall
- func (c *BackupsUpdateBackupCall) Header() http.Header
- func (c *BackupsUpdateBackupCall) UpdateMask(updateMask string) *BackupsUpdateBackupCall
- type BinLogCoordinates
- type CloneContext
- type Column
- type ConnectGenerateEphemeralCertCall
- func (c *ConnectGenerateEphemeralCertCall) Context(ctx context.Context) *ConnectGenerateEphemeralCertCall
- func (c *ConnectGenerateEphemeralCertCall) Do(opts ...googleapi.CallOption) (*GenerateEphemeralCertResponse, error)
- func (c *ConnectGenerateEphemeralCertCall) Fields(s ...googleapi.Field) *ConnectGenerateEphemeralCertCall
- func (c *ConnectGenerateEphemeralCertCall) Header() http.Header
- type ConnectGetCall
- func (c *ConnectGetCall) Context(ctx context.Context) *ConnectGetCall
- func (c *ConnectGetCall) Do(opts ...googleapi.CallOption) (*ConnectSettings, error)
- func (c *ConnectGetCall) Fields(s ...googleapi.Field) *ConnectGetCall
- func (c *ConnectGetCall) Header() http.Header
- func (c *ConnectGetCall) IfNoneMatch(entityTag string) *ConnectGetCall
- func (c *ConnectGetCall) ReadTime(readTime string) *ConnectGetCall
- type ConnectPoolNodeConfig
- type ConnectService
- type ConnectSettings
- type ConnectionPoolConfig
- type ConnectionPoolFlags
- type DataCacheConfig
- type Database
- type DatabaseFlags
- type DatabaseInstance
- type DatabaseInstanceFailoverReplica
- type DatabasesDeleteCall
- type DatabasesGetCall
- func (c *DatabasesGetCall) Context(ctx context.Context) *DatabasesGetCall
- func (c *DatabasesGetCall) Do(opts ...googleapi.CallOption) (*Database, error)
- func (c *DatabasesGetCall) Fields(s ...googleapi.Field) *DatabasesGetCall
- func (c *DatabasesGetCall) Header() http.Header
- func (c *DatabasesGetCall) IfNoneMatch(entityTag string) *DatabasesGetCall
- type DatabasesInsertCall
- type DatabasesListCall
- func (c *DatabasesListCall) Context(ctx context.Context) *DatabasesListCall
- func (c *DatabasesListCall) Do(opts ...googleapi.CallOption) (*DatabasesListResponse, error)
- func (c *DatabasesListCall) Fields(s ...googleapi.Field) *DatabasesListCall
- func (c *DatabasesListCall) Header() http.Header
- func (c *DatabasesListCall) IfNoneMatch(entityTag string) *DatabasesListCall
- type DatabasesListResponse
- type DatabasesPatchCall
- type DatabasesService
- func (r *DatabasesService) Delete(project string, instance string, database string) *DatabasesDeleteCall
- func (r *DatabasesService) Get(project string, instance string, database string) *DatabasesGetCall
- func (r *DatabasesService) Insert(project string, instance string, database *Database) *DatabasesInsertCall
- func (r *DatabasesService) List(project string, instance string) *DatabasesListCall
- func (r *DatabasesService) Patch(project string, instance string, database string, database2 *Database) *DatabasesPatchCall
- func (r *DatabasesService) Update(project string, instance string, database string, database2 *Database) *DatabasesUpdateCall
- type DatabasesUpdateCall
- type DemoteContext
- type DemoteMasterConfiguration
- type DemoteMasterContext
- type DemoteMasterMySqlReplicaConfiguration
- type DenyMaintenancePeriod
- type DiskEncryptionConfiguration
- type DiskEncryptionStatus
- type DnsNameMapping
- type Empty
- type ExecuteSqlPayload
- type ExportContext
- type ExportContextBakExportOptions
- type ExportContextCsvExportOptions
- type ExportContextSqlExportOptions
- type ExportContextSqlExportOptionsMysqlExportOptions
- type ExportContextSqlExportOptionsPostgresExportOptions
- type ExportContextTdeExportOptions
- type ExternalSyncSelectedObject
- type FailoverContext
- type FinalBackupConfig
- type Flag
- type FlagsListCall
- func (c *FlagsListCall) Context(ctx context.Context) *FlagsListCall
- func (c *FlagsListCall) DatabaseVersion(databaseVersion string) *FlagsListCall
- func (c *FlagsListCall) Do(opts ...googleapi.CallOption) (*FlagsListResponse, error)
- func (c *FlagsListCall) Fields(s ...googleapi.Field) *FlagsListCall
- func (c *FlagsListCall) FlagScope(flagScope string) *FlagsListCall
- func (c *FlagsListCall) Header() http.Header
- func (c *FlagsListCall) IfNoneMatch(entityTag string) *FlagsListCall
- type FlagsListResponse
- type FlagsService
- type GeminiInstanceConfig
- type GenerateEphemeralCertRequest
- type GenerateEphemeralCertResponse
- type ImportContext
- type ImportContextBakImportOptions
- type ImportContextBakImportOptionsEncryptionOptions
- type ImportContextCsvImportOptions
- type ImportContextSqlImportOptions
- type ImportContextSqlImportOptionsPostgresImportOptions
- type ImportContextTdeImportOptions
- type InsightsConfig
- type InstanceReference
- type InstancesAcquireSsrsLeaseCall
- func (c *InstancesAcquireSsrsLeaseCall) Context(ctx context.Context) *InstancesAcquireSsrsLeaseCall
- func (c *InstancesAcquireSsrsLeaseCall) Do(opts ...googleapi.CallOption) (*SqlInstancesAcquireSsrsLeaseResponse, error)
- func (c *InstancesAcquireSsrsLeaseCall) Fields(s ...googleapi.Field) *InstancesAcquireSsrsLeaseCall
- func (c *InstancesAcquireSsrsLeaseCall) Header() http.Header
- type InstancesAcquireSsrsLeaseRequest
- type InstancesAddServerCaCall
- func (c *InstancesAddServerCaCall) Context(ctx context.Context) *InstancesAddServerCaCall
- func (c *InstancesAddServerCaCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesAddServerCaCall) Fields(s ...googleapi.Field) *InstancesAddServerCaCall
- func (c *InstancesAddServerCaCall) Header() http.Header
- type InstancesAddServerCertificateCall
- func (c *InstancesAddServerCertificateCall) Context(ctx context.Context) *InstancesAddServerCertificateCall
- func (c *InstancesAddServerCertificateCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesAddServerCertificateCall) Fields(s ...googleapi.Field) *InstancesAddServerCertificateCall
- func (c *InstancesAddServerCertificateCall) Header() http.Header
- type InstancesCloneCall
- type InstancesCloneRequest
- type InstancesDeleteCall
- func (c *InstancesDeleteCall) Context(ctx context.Context) *InstancesDeleteCall
- func (c *InstancesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesDeleteCall) EnableFinalBackup(enableFinalBackup bool) *InstancesDeleteCall
- func (c *InstancesDeleteCall) Fields(s ...googleapi.Field) *InstancesDeleteCall
- func (c *InstancesDeleteCall) FinalBackupDescription(finalBackupDescription string) *InstancesDeleteCall
- func (c *InstancesDeleteCall) FinalBackupExpiryTime(finalBackupExpiryTime string) *InstancesDeleteCall
- func (c *InstancesDeleteCall) FinalBackupTtlDays(finalBackupTtlDays int64) *InstancesDeleteCall
- func (c *InstancesDeleteCall) Header() http.Header
- type InstancesDemoteCall
- type InstancesDemoteMasterCall
- func (c *InstancesDemoteMasterCall) Context(ctx context.Context) *InstancesDemoteMasterCall
- func (c *InstancesDemoteMasterCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesDemoteMasterCall) Fields(s ...googleapi.Field) *InstancesDemoteMasterCall
- func (c *InstancesDemoteMasterCall) Header() http.Header
- type InstancesDemoteMasterRequest
- type InstancesDemoteRequest
- type InstancesExecuteSqlCall
- func (c *InstancesExecuteSqlCall) Context(ctx context.Context) *InstancesExecuteSqlCall
- func (c *InstancesExecuteSqlCall) Do(opts ...googleapi.CallOption) (*SqlInstancesExecuteSqlResponse, error)
- func (c *InstancesExecuteSqlCall) Fields(s ...googleapi.Field) *InstancesExecuteSqlCall
- func (c *InstancesExecuteSqlCall) Header() http.Header
- type InstancesExportCall
- type InstancesExportRequest
- type InstancesFailoverCall
- func (c *InstancesFailoverCall) Context(ctx context.Context) *InstancesFailoverCall
- func (c *InstancesFailoverCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesFailoverCall) Fields(s ...googleapi.Field) *InstancesFailoverCall
- func (c *InstancesFailoverCall) Header() http.Header
- type InstancesFailoverRequest
- type InstancesGetCall
- func (c *InstancesGetCall) Context(ctx context.Context) *InstancesGetCall
- func (c *InstancesGetCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
- func (c *InstancesGetCall) Fields(s ...googleapi.Field) *InstancesGetCall
- func (c *InstancesGetCall) Header() http.Header
- func (c *InstancesGetCall) IfNoneMatch(entityTag string) *InstancesGetCall
- type InstancesImportCall
- type InstancesImportRequest
- type InstancesInsertCall
- type InstancesListCall
- func (c *InstancesListCall) Context(ctx context.Context) *InstancesListCall
- func (c *InstancesListCall) Do(opts ...googleapi.CallOption) (*InstancesListResponse, error)
- func (c *InstancesListCall) Fields(s ...googleapi.Field) *InstancesListCall
- func (c *InstancesListCall) Filter(filter string) *InstancesListCall
- func (c *InstancesListCall) Header() http.Header
- func (c *InstancesListCall) IfNoneMatch(entityTag string) *InstancesListCall
- func (c *InstancesListCall) MaxResults(maxResults int64) *InstancesListCall
- func (c *InstancesListCall) PageToken(pageToken string) *InstancesListCall
- func (c *InstancesListCall) Pages(ctx context.Context, f func(*InstancesListResponse) error) error
- type InstancesListEntraIdCertificatesCall
- func (c *InstancesListEntraIdCertificatesCall) Context(ctx context.Context) *InstancesListEntraIdCertificatesCall
- func (c *InstancesListEntraIdCertificatesCall) Do(opts ...googleapi.CallOption) (*InstancesListEntraIdCertificatesResponse, error)
- func (c *InstancesListEntraIdCertificatesCall) Fields(s ...googleapi.Field) *InstancesListEntraIdCertificatesCall
- func (c *InstancesListEntraIdCertificatesCall) Header() http.Header
- func (c *InstancesListEntraIdCertificatesCall) IfNoneMatch(entityTag string) *InstancesListEntraIdCertificatesCall
- type InstancesListEntraIdCertificatesResponse
- type InstancesListResponse
- type InstancesListServerCasCall
- func (c *InstancesListServerCasCall) Context(ctx context.Context) *InstancesListServerCasCall
- func (c *InstancesListServerCasCall) Do(opts ...googleapi.CallOption) (*InstancesListServerCasResponse, error)
- func (c *InstancesListServerCasCall) Fields(s ...googleapi.Field) *InstancesListServerCasCall
- func (c *InstancesListServerCasCall) Header() http.Header
- func (c *InstancesListServerCasCall) IfNoneMatch(entityTag string) *InstancesListServerCasCall
- type InstancesListServerCasResponse
- type InstancesListServerCertificatesCall
- func (c *InstancesListServerCertificatesCall) Context(ctx context.Context) *InstancesListServerCertificatesCall
- func (c *InstancesListServerCertificatesCall) Do(opts ...googleapi.CallOption) (*InstancesListServerCertificatesResponse, error)
- func (c *InstancesListServerCertificatesCall) Fields(s ...googleapi.Field) *InstancesListServerCertificatesCall
- func (c *InstancesListServerCertificatesCall) Header() http.Header
- func (c *InstancesListServerCertificatesCall) IfNoneMatch(entityTag string) *InstancesListServerCertificatesCall
- type InstancesListServerCertificatesResponse
- type InstancesPatchCall
- type InstancesPointInTimeRestoreCall
- func (c *InstancesPointInTimeRestoreCall) Context(ctx context.Context) *InstancesPointInTimeRestoreCall
- func (c *InstancesPointInTimeRestoreCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesPointInTimeRestoreCall) Fields(s ...googleapi.Field) *InstancesPointInTimeRestoreCall
- func (c *InstancesPointInTimeRestoreCall) Header() http.Header
- type InstancesPreCheckMajorVersionUpgradeCall
- func (c *InstancesPreCheckMajorVersionUpgradeCall) Context(ctx context.Context) *InstancesPreCheckMajorVersionUpgradeCall
- func (c *InstancesPreCheckMajorVersionUpgradeCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesPreCheckMajorVersionUpgradeCall) Fields(s ...googleapi.Field) *InstancesPreCheckMajorVersionUpgradeCall
- func (c *InstancesPreCheckMajorVersionUpgradeCall) Header() http.Header
- type InstancesPreCheckMajorVersionUpgradeRequest
- type InstancesPromoteReplicaCall
- func (c *InstancesPromoteReplicaCall) Context(ctx context.Context) *InstancesPromoteReplicaCall
- func (c *InstancesPromoteReplicaCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesPromoteReplicaCall) Failover(failover bool) *InstancesPromoteReplicaCall
- func (c *InstancesPromoteReplicaCall) Fields(s ...googleapi.Field) *InstancesPromoteReplicaCall
- func (c *InstancesPromoteReplicaCall) Header() http.Header
- type InstancesReencryptCall
- func (c *InstancesReencryptCall) Context(ctx context.Context) *InstancesReencryptCall
- func (c *InstancesReencryptCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesReencryptCall) Fields(s ...googleapi.Field) *InstancesReencryptCall
- func (c *InstancesReencryptCall) Header() http.Header
- type InstancesReencryptRequest
- type InstancesReleaseSsrsLeaseCall
- func (c *InstancesReleaseSsrsLeaseCall) Context(ctx context.Context) *InstancesReleaseSsrsLeaseCall
- func (c *InstancesReleaseSsrsLeaseCall) Do(opts ...googleapi.CallOption) (*SqlInstancesReleaseSsrsLeaseResponse, error)
- func (c *InstancesReleaseSsrsLeaseCall) Fields(s ...googleapi.Field) *InstancesReleaseSsrsLeaseCall
- func (c *InstancesReleaseSsrsLeaseCall) Header() http.Header
- type InstancesResetSslConfigCall
- func (c *InstancesResetSslConfigCall) Context(ctx context.Context) *InstancesResetSslConfigCall
- func (c *InstancesResetSslConfigCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesResetSslConfigCall) Fields(s ...googleapi.Field) *InstancesResetSslConfigCall
- func (c *InstancesResetSslConfigCall) Header() http.Header
- func (c *InstancesResetSslConfigCall) Mode(mode string) *InstancesResetSslConfigCall
- type InstancesRestartCall
- type InstancesRestoreBackupCall
- func (c *InstancesRestoreBackupCall) Context(ctx context.Context) *InstancesRestoreBackupCall
- func (c *InstancesRestoreBackupCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesRestoreBackupCall) Fields(s ...googleapi.Field) *InstancesRestoreBackupCall
- func (c *InstancesRestoreBackupCall) Header() http.Header
- type InstancesRestoreBackupRequest
- type InstancesRotateEntraIdCertificateCall
- func (c *InstancesRotateEntraIdCertificateCall) Context(ctx context.Context) *InstancesRotateEntraIdCertificateCall
- func (c *InstancesRotateEntraIdCertificateCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesRotateEntraIdCertificateCall) Fields(s ...googleapi.Field) *InstancesRotateEntraIdCertificateCall
- func (c *InstancesRotateEntraIdCertificateCall) Header() http.Header
- type InstancesRotateEntraIdCertificateRequest
- type InstancesRotateServerCaCall
- func (c *InstancesRotateServerCaCall) Context(ctx context.Context) *InstancesRotateServerCaCall
- func (c *InstancesRotateServerCaCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesRotateServerCaCall) Fields(s ...googleapi.Field) *InstancesRotateServerCaCall
- func (c *InstancesRotateServerCaCall) Header() http.Header
- type InstancesRotateServerCaRequest
- type InstancesRotateServerCertificateCall
- func (c *InstancesRotateServerCertificateCall) Context(ctx context.Context) *InstancesRotateServerCertificateCall
- func (c *InstancesRotateServerCertificateCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesRotateServerCertificateCall) Fields(s ...googleapi.Field) *InstancesRotateServerCertificateCall
- func (c *InstancesRotateServerCertificateCall) Header() http.Header
- type InstancesRotateServerCertificateRequest
- type InstancesService
- func (r *InstancesService) AcquireSsrsLease(project string, instance string, ...) *InstancesAcquireSsrsLeaseCall
- func (r *InstancesService) AddServerCa(project string, instance string) *InstancesAddServerCaCall
- func (r *InstancesService) AddServerCertificate(project string, instance string) *InstancesAddServerCertificateCall
- func (r *InstancesService) Clone(project string, instance string, instancesclonerequest *InstancesCloneRequest) *InstancesCloneCall
- func (r *InstancesService) Delete(project string, instance string) *InstancesDeleteCall
- func (r *InstancesService) Demote(project string, instance string, ...) *InstancesDemoteCall
- func (r *InstancesService) DemoteMaster(project string, instance string, ...) *InstancesDemoteMasterCall
- func (r *InstancesService) ExecuteSql(project string, instance string, executesqlpayload *ExecuteSqlPayload) *InstancesExecuteSqlCall
- func (r *InstancesService) Export(project string, instance string, ...) *InstancesExportCall
- func (r *InstancesService) Failover(project string, instance string, ...) *InstancesFailoverCall
- 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) ListEntraIdCertificates(project string, instance string) *InstancesListEntraIdCertificatesCall
- func (r *InstancesService) ListServerCas(project string, instance string) *InstancesListServerCasCall
- func (r *InstancesService) ListServerCertificates(project string, instance string) *InstancesListServerCertificatesCall
- func (r *InstancesService) Patch(project string, instance string, databaseinstance *DatabaseInstance) *InstancesPatchCall
- func (r *InstancesService) PointInTimeRestore(parent string, pointintimerestorecontext *PointInTimeRestoreContext) *InstancesPointInTimeRestoreCall
- func (r *InstancesService) PreCheckMajorVersionUpgrade(project string, instance string, ...) *InstancesPreCheckMajorVersionUpgradeCall
- func (r *InstancesService) PromoteReplica(project string, instance string) *InstancesPromoteReplicaCall
- func (r *InstancesService) Reencrypt(project string, instance string, ...) *InstancesReencryptCall
- func (r *InstancesService) ReleaseSsrsLease(project string, instance string) *InstancesReleaseSsrsLeaseCall
- 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, ...) *InstancesRestoreBackupCall
- func (r *InstancesService) RotateEntraIdCertificate(project string, instance string, ...) *InstancesRotateEntraIdCertificateCall
- func (r *InstancesService) RotateServerCa(project string, instance string, ...) *InstancesRotateServerCaCall
- func (r *InstancesService) RotateServerCertificate(project string, instance string, ...) *InstancesRotateServerCertificateCall
- func (r *InstancesService) StartReplica(project string, instance string) *InstancesStartReplicaCall
- func (r *InstancesService) StopReplica(project string, instance string) *InstancesStopReplicaCall
- func (r *InstancesService) Switchover(project string, instance string) *InstancesSwitchoverCall
- func (r *InstancesService) TruncateLog(project string, instance string, ...) *InstancesTruncateLogCall
- func (r *InstancesService) Update(project string, instance string, databaseinstance *DatabaseInstance) *InstancesUpdateCall
- type InstancesStartReplicaCall
- func (c *InstancesStartReplicaCall) Context(ctx context.Context) *InstancesStartReplicaCall
- func (c *InstancesStartReplicaCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesStartReplicaCall) Fields(s ...googleapi.Field) *InstancesStartReplicaCall
- func (c *InstancesStartReplicaCall) Header() http.Header
- type InstancesStopReplicaCall
- func (c *InstancesStopReplicaCall) Context(ctx context.Context) *InstancesStopReplicaCall
- func (c *InstancesStopReplicaCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesStopReplicaCall) Fields(s ...googleapi.Field) *InstancesStopReplicaCall
- func (c *InstancesStopReplicaCall) Header() http.Header
- type InstancesSwitchoverCall
- func (c *InstancesSwitchoverCall) Context(ctx context.Context) *InstancesSwitchoverCall
- func (c *InstancesSwitchoverCall) DbTimeout(dbTimeout string) *InstancesSwitchoverCall
- func (c *InstancesSwitchoverCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesSwitchoverCall) Fields(s ...googleapi.Field) *InstancesSwitchoverCall
- func (c *InstancesSwitchoverCall) Header() http.Header
- type InstancesTruncateLogCall
- func (c *InstancesTruncateLogCall) Context(ctx context.Context) *InstancesTruncateLogCall
- func (c *InstancesTruncateLogCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *InstancesTruncateLogCall) Fields(s ...googleapi.Field) *InstancesTruncateLogCall
- func (c *InstancesTruncateLogCall) Header() http.Header
- type InstancesTruncateLogRequest
- type InstancesUpdateCall
- type Interval
- type IpConfiguration
- type IpMapping
- type ListBackupsResponse
- type LocationPreference
- type MaintenanceWindow
- type Message
- type Metadata
- type MySqlReplicaConfiguration
- type MySqlSyncConfig
- type OnPremisesConfiguration
- type Operation
- type OperationError
- type OperationErrors
- type OperationMetadata
- type OperationsCancelCall
- type OperationsGetCall
- func (c *OperationsGetCall) Context(ctx context.Context) *OperationsGetCall
- func (c *OperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *OperationsGetCall) Fields(s ...googleapi.Field) *OperationsGetCall
- func (c *OperationsGetCall) Header() http.Header
- func (c *OperationsGetCall) IfNoneMatch(entityTag string) *OperationsGetCall
- type OperationsListCall
- func (c *OperationsListCall) Context(ctx context.Context) *OperationsListCall
- func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*OperationsListResponse, error)
- func (c *OperationsListCall) Fields(s ...googleapi.Field) *OperationsListCall
- func (c *OperationsListCall) Header() http.Header
- func (c *OperationsListCall) IfNoneMatch(entityTag string) *OperationsListCall
- func (c *OperationsListCall) Instance(instance string) *OperationsListCall
- func (c *OperationsListCall) MaxResults(maxResults int64) *OperationsListCall
- func (c *OperationsListCall) PageToken(pageToken string) *OperationsListCall
- func (c *OperationsListCall) Pages(ctx context.Context, f func(*OperationsListResponse) error) error
- type OperationsListResponse
- type OperationsService
- type PasswordStatus
- type PasswordValidationPolicy
- type PerformDiskShrinkContext
- type PointInTimeRestoreContext
- type PoolNodeConfig
- type PreCheckMajorVersionUpgradeContext
- type PreCheckResponse
- type ProjectsInstancesGetDiskShrinkConfigCall
- func (c *ProjectsInstancesGetDiskShrinkConfigCall) Context(ctx context.Context) *ProjectsInstancesGetDiskShrinkConfigCall
- func (c *ProjectsInstancesGetDiskShrinkConfigCall) Do(opts ...googleapi.CallOption) (*SqlInstancesGetDiskShrinkConfigResponse, error)
- func (c *ProjectsInstancesGetDiskShrinkConfigCall) Fields(s ...googleapi.Field) *ProjectsInstancesGetDiskShrinkConfigCall
- func (c *ProjectsInstancesGetDiskShrinkConfigCall) Header() http.Header
- func (c *ProjectsInstancesGetDiskShrinkConfigCall) IfNoneMatch(entityTag string) *ProjectsInstancesGetDiskShrinkConfigCall
- type ProjectsInstancesGetLatestRecoveryTimeCall
- func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Context(ctx context.Context) *ProjectsInstancesGetLatestRecoveryTimeCall
- func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Do(opts ...googleapi.CallOption) (*SqlInstancesGetLatestRecoveryTimeResponse, error)
- func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Fields(s ...googleapi.Field) *ProjectsInstancesGetLatestRecoveryTimeCall
- func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Header() http.Header
- func (c *ProjectsInstancesGetLatestRecoveryTimeCall) IfNoneMatch(entityTag string) *ProjectsInstancesGetLatestRecoveryTimeCall
- func (c *ProjectsInstancesGetLatestRecoveryTimeCall) SourceInstanceDeletionTime(sourceInstanceDeletionTime string) *ProjectsInstancesGetLatestRecoveryTimeCall
- type ProjectsInstancesPerformDiskShrinkCall
- func (c *ProjectsInstancesPerformDiskShrinkCall) Context(ctx context.Context) *ProjectsInstancesPerformDiskShrinkCall
- func (c *ProjectsInstancesPerformDiskShrinkCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsInstancesPerformDiskShrinkCall) Fields(s ...googleapi.Field) *ProjectsInstancesPerformDiskShrinkCall
- func (c *ProjectsInstancesPerformDiskShrinkCall) Header() http.Header
- type ProjectsInstancesRescheduleMaintenanceCall
- func (c *ProjectsInstancesRescheduleMaintenanceCall) Context(ctx context.Context) *ProjectsInstancesRescheduleMaintenanceCall
- func (c *ProjectsInstancesRescheduleMaintenanceCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsInstancesRescheduleMaintenanceCall) Fields(s ...googleapi.Field) *ProjectsInstancesRescheduleMaintenanceCall
- func (c *ProjectsInstancesRescheduleMaintenanceCall) Header() http.Header
- type ProjectsInstancesResetReplicaSizeCall
- func (c *ProjectsInstancesResetReplicaSizeCall) Context(ctx context.Context) *ProjectsInstancesResetReplicaSizeCall
- func (c *ProjectsInstancesResetReplicaSizeCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsInstancesResetReplicaSizeCall) Fields(s ...googleapi.Field) *ProjectsInstancesResetReplicaSizeCall
- func (c *ProjectsInstancesResetReplicaSizeCall) Header() http.Header
- type ProjectsInstancesService
- func (r *ProjectsInstancesService) GetDiskShrinkConfig(project string, instance string) *ProjectsInstancesGetDiskShrinkConfigCall
- func (r *ProjectsInstancesService) GetLatestRecoveryTime(project string, instance string) *ProjectsInstancesGetLatestRecoveryTimeCall
- func (r *ProjectsInstancesService) PerformDiskShrink(project string, instance string, ...) *ProjectsInstancesPerformDiskShrinkCall
- func (r *ProjectsInstancesService) RescheduleMaintenance(project string, instance string, ...) *ProjectsInstancesRescheduleMaintenanceCall
- func (r *ProjectsInstancesService) ResetReplicaSize(project string, instance string, ...) *ProjectsInstancesResetReplicaSizeCall
- func (r *ProjectsInstancesService) StartExternalSync(project string, instance string, ...) *ProjectsInstancesStartExternalSyncCall
- func (r *ProjectsInstancesService) VerifyExternalSyncSettings(project string, instance string, ...) *ProjectsInstancesVerifyExternalSyncSettingsCall
- type ProjectsInstancesStartExternalSyncCall
- func (c *ProjectsInstancesStartExternalSyncCall) Context(ctx context.Context) *ProjectsInstancesStartExternalSyncCall
- func (c *ProjectsInstancesStartExternalSyncCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *ProjectsInstancesStartExternalSyncCall) Fields(s ...googleapi.Field) *ProjectsInstancesStartExternalSyncCall
- func (c *ProjectsInstancesStartExternalSyncCall) Header() http.Header
- type ProjectsInstancesVerifyExternalSyncSettingsCall
- func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Context(ctx context.Context) *ProjectsInstancesVerifyExternalSyncSettingsCall
- func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Do(opts ...googleapi.CallOption) (*SqlInstancesVerifyExternalSyncSettingsResponse, error)
- func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Fields(s ...googleapi.Field) *ProjectsInstancesVerifyExternalSyncSettingsCall
- func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Header() http.Header
- type ProjectsService
- type PscAutoConnectionConfig
- type PscConfig
- type QueryResult
- type ReadPoolAutoScaleConfig
- type ReplicaConfiguration
- type ReplicationCluster
- type Reschedule
- type RestoreBackupContext
- type RotateEntraIdCertificateContext
- type RotateServerCaContext
- type RotateServerCertificateContext
- type Row
- type SelectedObjects
- type Service
- type Settings
- type SqlActiveDirectoryConfig
- type SqlExternalSyncSettingError
- type SqlInstancesAcquireSsrsLeaseResponse
- type SqlInstancesExecuteSqlResponse
- type SqlInstancesGetDiskShrinkConfigResponse
- type SqlInstancesGetLatestRecoveryTimeResponse
- type SqlInstancesReleaseSsrsLeaseResponse
- type SqlInstancesRescheduleMaintenanceRequestBody
- type SqlInstancesResetReplicaSizeRequest
- type SqlInstancesStartExternalSyncRequest
- type SqlInstancesVerifyExternalSyncSettingsRequest
- type SqlInstancesVerifyExternalSyncSettingsResponse
- type SqlOutOfDiskReport
- type SqlScheduledMaintenance
- type SqlServerAuditConfig
- type SqlServerDatabaseDetails
- type SqlServerEntraIdConfig
- type SqlServerUserDetails
- type SqlSubOperationType
- type SslCert
- type SslCertDetail
- type SslCertsCreateEphemeralCall
- func (c *SslCertsCreateEphemeralCall) Context(ctx context.Context) *SslCertsCreateEphemeralCall
- func (c *SslCertsCreateEphemeralCall) Do(opts ...googleapi.CallOption) (*SslCert, error)
- func (c *SslCertsCreateEphemeralCall) Fields(s ...googleapi.Field) *SslCertsCreateEphemeralCall
- func (c *SslCertsCreateEphemeralCall) Header() http.Header
- type SslCertsCreateEphemeralRequest
- type SslCertsDeleteCall
- type SslCertsGetCall
- func (c *SslCertsGetCall) Context(ctx context.Context) *SslCertsGetCall
- func (c *SslCertsGetCall) Do(opts ...googleapi.CallOption) (*SslCert, error)
- func (c *SslCertsGetCall) Fields(s ...googleapi.Field) *SslCertsGetCall
- func (c *SslCertsGetCall) Header() http.Header
- func (c *SslCertsGetCall) IfNoneMatch(entityTag string) *SslCertsGetCall
- type SslCertsInsertCall
- type SslCertsInsertRequest
- type SslCertsInsertResponse
- type SslCertsListCall
- func (c *SslCertsListCall) Context(ctx context.Context) *SslCertsListCall
- func (c *SslCertsListCall) Do(opts ...googleapi.CallOption) (*SslCertsListResponse, error)
- func (c *SslCertsListCall) Fields(s ...googleapi.Field) *SslCertsListCall
- func (c *SslCertsListCall) Header() http.Header
- func (c *SslCertsListCall) IfNoneMatch(entityTag string) *SslCertsListCall
- type SslCertsListResponse
- type SslCertsService
- func (r *SslCertsService) CreateEphemeral(project string, instance string, ...) *SslCertsCreateEphemeralCall
- 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 Status
- type SyncFlags
- type TargetMetric
- type Tier
- type TiersListCall
- func (c *TiersListCall) Context(ctx context.Context) *TiersListCall
- func (c *TiersListCall) Do(opts ...googleapi.CallOption) (*TiersListResponse, error)
- func (c *TiersListCall) Fields(s ...googleapi.Field) *TiersListCall
- func (c *TiersListCall) Header() http.Header
- func (c *TiersListCall) IfNoneMatch(entityTag string) *TiersListCall
- type TiersListResponse
- type TiersService
- type TruncateLogContext
- type User
- type UserPasswordValidationPolicy
- type UsersDeleteCall
- func (c *UsersDeleteCall) Context(ctx context.Context) *UsersDeleteCall
- func (c *UsersDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *UsersDeleteCall) Fields(s ...googleapi.Field) *UsersDeleteCall
- func (c *UsersDeleteCall) Header() http.Header
- func (c *UsersDeleteCall) Host(host string) *UsersDeleteCall
- func (c *UsersDeleteCall) Name(name string) *UsersDeleteCall
- type UsersGetCall
- func (c *UsersGetCall) Context(ctx context.Context) *UsersGetCall
- func (c *UsersGetCall) Do(opts ...googleapi.CallOption) (*User, error)
- func (c *UsersGetCall) Fields(s ...googleapi.Field) *UsersGetCall
- func (c *UsersGetCall) Header() http.Header
- func (c *UsersGetCall) Host(host string) *UsersGetCall
- func (c *UsersGetCall) IfNoneMatch(entityTag string) *UsersGetCall
- type UsersInsertCall
- type UsersListCall
- func (c *UsersListCall) Context(ctx context.Context) *UsersListCall
- func (c *UsersListCall) Do(opts ...googleapi.CallOption) (*UsersListResponse, error)
- func (c *UsersListCall) Fields(s ...googleapi.Field) *UsersListCall
- func (c *UsersListCall) Header() http.Header
- func (c *UsersListCall) IfNoneMatch(entityTag string) *UsersListCall
- type UsersListResponse
- type UsersService
- func (r *UsersService) Delete(project string, instance string) *UsersDeleteCall
- func (r *UsersService) Get(project string, instance string, name string) *UsersGetCall
- func (r *UsersService) Insert(project string, instance string, user *User) *UsersInsertCall
- func (r *UsersService) List(project string, instance string) *UsersListCall
- func (r *UsersService) Update(project string, instance string, user *User) *UsersUpdateCall
- type UsersUpdateCall
- func (c *UsersUpdateCall) Context(ctx context.Context) *UsersUpdateCall
- func (c *UsersUpdateCall) DatabaseRoles(databaseRoles ...string) *UsersUpdateCall
- func (c *UsersUpdateCall) Do(opts ...googleapi.CallOption) (*Operation, error)
- func (c *UsersUpdateCall) Fields(s ...googleapi.Field) *UsersUpdateCall
- func (c *UsersUpdateCall) Header() http.Header
- func (c *UsersUpdateCall) Host(host string) *UsersUpdateCall
- func (c *UsersUpdateCall) Name(name string) *UsersUpdateCall
- type Value
Constants¶
const (// See, edit, configure, and delete your Google Cloud data and see the email// address for your Google Account.CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"// Manage your Google SQL Service instancesSqlserviceAdminScope = "https://www.googleapis.com/auth/sqlservice.admin")
OAuth2 scopes used by this API.
Variables¶
This section is empty.
Functions¶
This section is empty.
Types¶
typeAclEntry¶
type AclEntry struct {// ExpirationTime: The time when this access control entry expires inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.ExpirationTimestring `json:"expirationTime,omitempty"`// Kind: This is always `sql#aclEntry`.Kindstring `json:"kind,omitempty"`// Name: Optional. A label to identify this entry.Namestring `json:"name,omitempty"`// Value: The allowlisted value for the access control list.Valuestring `json:"value,omitempty"`// ForceSendFields is a list of field names (e.g. "ExpirationTime") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ExpirationTime") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AclEntry: An entry for an Access Control list.
func (AclEntry)MarshalJSON¶
typeAcquireSsrsLeaseContext¶added inv0.170.0
type AcquireSsrsLeaseContext struct {// Duration: Lease duration needed for SSRS setup.Durationstring `json:"duration,omitempty"`// ReportDatabase: The report database to be used for SSRS setup.ReportDatabasestring `json:"reportDatabase,omitempty"`// ServiceLogin: The username to be used as the service login to connect to the// report database for SSRS setup.ServiceLoginstring `json:"serviceLogin,omitempty"`// SetupLogin: The username to be used as the setup login to connect to the// database server for SSRS setup.SetupLoginstring `json:"setupLogin,omitempty"`// ForceSendFields is a list of field names (e.g. "Duration") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Duration") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AcquireSsrsLeaseContext: Acquire SSRS lease context.
func (AcquireSsrsLeaseContext)MarshalJSON¶added inv0.170.0
func (sAcquireSsrsLeaseContext) MarshalJSON() ([]byte,error)
typeAdvancedMachineFeatures¶added inv0.117.0
type AdvancedMachineFeatures struct {// ThreadsPerCore: The number of threads per physical core.ThreadsPerCoreint64 `json:"threadsPerCore,omitempty"`// ForceSendFields is a list of field names (e.g. "ThreadsPerCore") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ThreadsPerCore") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AdvancedMachineFeatures: Specifies options for controlling advanced machinefeatures.
func (AdvancedMachineFeatures)MarshalJSON¶added inv0.117.0
func (sAdvancedMachineFeatures) MarshalJSON() ([]byte,error)
typeApiWarning¶
type ApiWarning struct {// Code: Code to uniquely identify the warning type.//// Possible values:// "SQL_API_WARNING_CODE_UNSPECIFIED" - An unknown or unset warning type from// Cloud SQL API.// "REGION_UNREACHABLE" - Warning when one or more regions are not reachable.// The returned result set may be incomplete.// "MAX_RESULTS_EXCEEDS_LIMIT" - Warning when user provided maxResults// parameter exceeds the limit. The returned result set may be incomplete.// "COMPROMISED_CREDENTIALS" - Warning when user tries to create/update a// user with credentials that have previously been compromised by a public data// breach.// "INTERNAL_STATE_FAILURE" - Warning when the operation succeeds but some// non-critical workflow state failed.Codestring `json:"code,omitempty"`// Message: The warning message.Messagestring `json:"message,omitempty"`// Region: The region name for REGION_UNREACHABLE warning.Regionstring `json:"region,omitempty"`// ForceSendFields is a list of field names (e.g. "Code") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Code") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ApiWarning: An Admin API warning message.
func (ApiWarning)MarshalJSON¶
func (sApiWarning) MarshalJSON() ([]byte,error)
typeAvailableDatabaseVersion¶added inv0.182.0
type AvailableDatabaseVersion struct {// DisplayName: The database version's display name.DisplayNamestring `json:"displayName,omitempty"`// MajorVersion: The version's major version name.MajorVersionstring `json:"majorVersion,omitempty"`// Name: The database version name. For MySQL 8.0, this string provides the// database major and minor version.Namestring `json:"name,omitempty"`// ForceSendFields is a list of field names (e.g. "DisplayName") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DisplayName") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}AvailableDatabaseVersion: An available database version. It can be a majoror a minor version.
func (AvailableDatabaseVersion)MarshalJSON¶added inv0.182.0
func (sAvailableDatabaseVersion) MarshalJSON() ([]byte,error)
typeBackup¶added inv0.222.0
type Backup struct {// BackupInterval: Output only. This output contains the following values:// start_time: All database writes up to this time are available. end_time: Any// database writes after this time aren't available.BackupInterval *Interval `json:"backupInterval,omitempty"`// BackupKind: Output only. Specifies the kind of backup, PHYSICAL or// DEFAULT_SNAPSHOT.//// Possible values:// "SQL_BACKUP_KIND_UNSPECIFIED" - This is an unknown BackupKind.// "SNAPSHOT" - Snapshot-based backups.// "PHYSICAL" - Physical backups.BackupKindstring `json:"backupKind,omitempty"`// BackupRun: Output only. The mapping to backup run resource used for IAM// validations.BackupRunstring `json:"backupRun,omitempty"`// DatabaseVersion: Output only. The database version of the instance of at the// time this backup was made.//// Possible values:// "SQL_DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version.// "MYSQL_5_1" - The database version is MySQL 5.1.// "MYSQL_5_5" - The database version is MySQL 5.5.// "MYSQL_5_6" - The database version is MySQL 5.6.// "MYSQL_5_7" - The database version is MySQL 5.7.// "MYSQL_8_0" - The database version is MySQL 8.// "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor// version is 18.// "MYSQL_8_0_26" - The database major version is MySQL 8.0 and the minor// version is 26.// "MYSQL_8_0_27" - The database major version is MySQL 8.0 and the minor// version is 27.// "MYSQL_8_0_28" - The database major version is MySQL 8.0 and the minor// version is 28.// "MYSQL_8_0_29" - The database major version is MySQL 8.0 and the minor// version is 29.// "MYSQL_8_0_30" - The database major version is MySQL 8.0 and the minor// version is 30.// "MYSQL_8_0_31" - The database major version is MySQL 8.0 and the minor// version is 31.// "MYSQL_8_0_32" - The database major version is MySQL 8.0 and the minor// version is 32.// "MYSQL_8_0_33" - The database major version is MySQL 8.0 and the minor// version is 33.// "MYSQL_8_0_34" - The database major version is MySQL 8.0 and the minor// version is 34.// "MYSQL_8_0_35" - The database major version is MySQL 8.0 and the minor// version is 35.// "MYSQL_8_0_36" - The database major version is MySQL 8.0 and the minor// version is 36.// "MYSQL_8_0_37" - The database major version is MySQL 8.0 and the minor// version is 37.// "MYSQL_8_0_39" - The database major version is MySQL 8.0 and the minor// version is 39.// "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor// version is 40.// "MYSQL_8_0_41" - The database major version is MySQL 8.0 and the minor// version is 41.// "MYSQL_8_0_42" - The database major version is MySQL 8.0 and the minor// version is 42.// "MYSQL_8_0_43" - The database major version is MySQL 8.0 and the minor// version is 43.// "MYSQL_8_0_44" - The database major version is MySQL 8.0 and the minor// version is 44.// "MYSQL_8_0_45" - The database major version is MySQL 8.0 and the minor// version is 45.// "MYSQL_8_0_46" - The database major version is MySQL 8.0 and the minor// version is 46.// "MYSQL_8_4" - The database version is MySQL 8.4.// "SQLSERVER_2017_STANDARD" - The database version is SQL Server 2017// Standard.// "SQLSERVER_2017_ENTERPRISE" - The database version is SQL Server 2017// Enterprise.// "SQLSERVER_2017_EXPRESS" - The database version is SQL Server 2017// Express.// "SQLSERVER_2017_WEB" - The database version is SQL Server 2017 Web.// "POSTGRES_9_6" - The database version is PostgreSQL 9.6.// "POSTGRES_10" - The database version is PostgreSQL 10.// "POSTGRES_11" - The database version is PostgreSQL 11.// "POSTGRES_12" - The database version is PostgreSQL 12.// "POSTGRES_13" - The database version is PostgreSQL 13.// "POSTGRES_14" - The database version is PostgreSQL 14.// "POSTGRES_15" - The database version is PostgreSQL 15.// "POSTGRES_16" - The database version is PostgreSQL 16.// "POSTGRES_17" - The database version is PostgreSQL 17.// "POSTGRES_18" - The database version is PostgreSQL 18.// "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019// Standard.// "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019// Enterprise.// "SQLSERVER_2019_EXPRESS" - The database version is SQL Server 2019// Express.// "SQLSERVER_2019_WEB" - The database version is SQL Server 2019 Web.// "SQLSERVER_2022_STANDARD" - The database version is SQL Server 2022// Standard.// "SQLSERVER_2022_ENTERPRISE" - The database version is SQL Server 2022// Enterprise.// "SQLSERVER_2022_EXPRESS" - The database version is SQL Server 2022// Express.// "SQLSERVER_2022_WEB" - The database version is SQL Server 2022 Web.DatabaseVersionstring `json:"databaseVersion,omitempty"`// Description: The description of this backup.Descriptionstring `json:"description,omitempty"`// Error: Output only. Information about why the backup operation fails (for// example, when the backup state fails).Error *OperationError `json:"error,omitempty"`// ExpiryTime: Backup expiration time. A UTC timestamp of when this backup// expired.ExpiryTimestring `json:"expiryTime,omitempty"`// Instance: The name of the source database instance.Instancestring `json:"instance,omitempty"`// InstanceDeletionTime: Optional. Output only. Timestamp in UTC of when the// instance associated with this backup is deleted.InstanceDeletionTimestring `json:"instanceDeletionTime,omitempty"`// InstanceSettings: Optional. Output only. The instance setting of the source// instance that's associated with this backup.InstanceSettings *DatabaseInstance `json:"instanceSettings,omitempty"`// Kind: Output only. This is always `sql#backup`.Kindstring `json:"kind,omitempty"`// KmsKey: Output only. This output contains the encryption configuration for a// backup and the resource name of the KMS key for disk encryption.KmsKeystring `json:"kmsKey,omitempty"`// KmsKeyVersion: Output only. This output contains the encryption status for a// backup and the version of the KMS key that's used to encrypt the Cloud SQL// instance.KmsKeyVersionstring `json:"kmsKeyVersion,omitempty"`// Location: The storage location of the backups. The location can be// multi-regional.Locationstring `json:"location,omitempty"`// MaxChargeableBytes: Output only. The maximum chargeable bytes for the// backup.MaxChargeableBytesint64 `json:"maxChargeableBytes,omitempty,string"`// Name: Output only. The resource name of the backup. Format:// projects/{project}/backups/{backup}.Namestring `json:"name,omitempty"`// SatisfiesPzi: Output only. This status indicates whether the backup// satisfies PZI. The status is reserved for future use.SatisfiesPzibool `json:"satisfiesPzi,omitempty"`// SatisfiesPzs: Output only. This status indicates whether the backup// satisfies PZS. The status is reserved for future use.SatisfiesPzsbool `json:"satisfiesPzs,omitempty"`// SelfLink: Output only. The URI of this resource.SelfLinkstring `json:"selfLink,omitempty"`// State: Output only. The status of this backup.//// Possible values:// "SQL_BACKUP_STATE_UNSPECIFIED" - The state of the backup is unknown.// "ENQUEUED" - The backup that's added to a queue.// "RUNNING" - The backup is in progress.// "FAILED" - The backup failed.// "SUCCESSFUL" - The backup is successful.// "DELETING" - The backup is being deleted.// "DELETION_FAILED" - Deletion of the backup failed.Statestring `json:"state,omitempty"`// TimeZone: Output only. This output contains a backup time zone. If a Cloud// SQL for SQL Server instance has a different time zone from the backup's time// zone, then the restore to the instance doesn't happen.TimeZonestring `json:"timeZone,omitempty"`// TtlDays: Input only. The time-to-live (TTL) interval for this resource (in// days). For example: ttlDays:7, means 7 days from the current time. The// expiration time can't exceed 365 days from the time that the backup is// created.TtlDaysint64 `json:"ttlDays,omitempty,string"`// Type: Output only. The type of this backup. The type can be "AUTOMATED",// "ON_DEMAND" or “FINAL”.//// Possible values:// "SQL_BACKUP_TYPE_UNSPECIFIED" - This is an unknown backup type.// "AUTOMATED" - The backup schedule triggers a backup automatically.// "ON_DEMAND" - The user triggers a backup manually.// "FINAL" - The backup created when instance is deleted.Typestring `json:"type,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "BackupInterval") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackupInterval") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Backup: A backup resource.
func (Backup)MarshalJSON¶added inv0.222.0
typeBackupConfiguration¶
type BackupConfiguration struct {// BackupRetentionSettings: Backup retention settings.BackupRetentionSettings *BackupRetentionSettings `json:"backupRetentionSettings,omitempty"`// BackupTier: Output only. Backup tier that manages the backups for the// instance.//// Possible values:// "BACKUP_TIER_UNSPECIFIED" - Unspecified.// "STANDARD" - Instance is managed by Cloud SQL.// "ADVANCED" - Deprecated: ADVANCED is deprecated. Please use ENHANCED// instead.// "ENHANCED" - Instance is managed by Google Cloud Backup and DR Service.BackupTierstring `json:"backupTier,omitempty"`// BinaryLogEnabled: (MySQL only) Whether binary log is enabled. If backup// configuration is disabled, binarylog must be disabled as well.BinaryLogEnabledbool `json:"binaryLogEnabled,omitempty"`// Enabled: Whether this configuration is enabled.Enabledbool `json:"enabled,omitempty"`// Kind: This is always `sql#backupConfiguration`.Kindstring `json:"kind,omitempty"`// Location: Location of the backupLocationstring `json:"location,omitempty"`// PointInTimeRecoveryEnabled: Whether point in time recovery is enabled.PointInTimeRecoveryEnabledbool `json:"pointInTimeRecoveryEnabled,omitempty"`// ReplicationLogArchivingEnabled: Reserved for future use.ReplicationLogArchivingEnabledbool `json:"replicationLogArchivingEnabled,omitempty"`// StartTime: Start time for the daily backup configuration in UTC timezone in// the 24 hour format - `HH:MM`.StartTimestring `json:"startTime,omitempty"`// TransactionLogRetentionDays: The number of days of transaction logs we// retain for point in time restore, from 1-7.TransactionLogRetentionDaysint64 `json:"transactionLogRetentionDays,omitempty"`// TransactionalLogStorageState: Output only. This value contains the storage// location of transactional logs used to perform point-in-time recovery (PITR)// for the database.//// Possible values:// "TRANSACTIONAL_LOG_STORAGE_STATE_UNSPECIFIED" - Unspecified.// "DISK" - The transaction logs used for PITR for the instance are stored on// a data disk.// "SWITCHING_TO_CLOUD_STORAGE" - The transaction logs used for PITR for the// instance are switching from being stored on a data disk to being stored in// Cloud Storage. Only applicable to MySQL.// "SWITCHED_TO_CLOUD_STORAGE" - The transaction logs used for PITR for the// instance are now stored in Cloud Storage. Previously, they were stored on a// data disk. Only applicable to MySQL.// "CLOUD_STORAGE" - The transaction logs used for PITR for the instance are// stored in Cloud Storage. Only applicable to MySQL and PostgreSQL.TransactionalLogStorageStatestring `json:"transactionalLogStorageState,omitempty"`// ForceSendFields is a list of field names (e.g. "BackupRetentionSettings") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackupRetentionSettings") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BackupConfiguration: Database instance backup configuration.
func (BackupConfiguration)MarshalJSON¶
func (sBackupConfiguration) MarshalJSON() ([]byte,error)
typeBackupContext¶added inv0.52.0
type BackupContext struct {// BackupId: The identifier of the backup.BackupIdint64 `json:"backupId,omitempty,string"`// Kind: This is always `sql#backupContext`.Kindstring `json:"kind,omitempty"`// Name: The name of the backup. Format: projects/{project}/backups/{backup}Namestring `json:"name,omitempty"`// ForceSendFields is a list of field names (e.g. "BackupId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackupId") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BackupContext: Backup context.
func (BackupContext)MarshalJSON¶added inv0.52.0
func (sBackupContext) MarshalJSON() ([]byte,error)
typeBackupReencryptionConfig¶added inv0.128.0
type BackupReencryptionConfig struct {// BackupLimit: Backup re-encryption limitBackupLimitint64 `json:"backupLimit,omitempty"`// BackupType: Type of backups users want to re-encrypt.//// Possible values:// "BACKUP_TYPE_UNSPECIFIED" - Unknown backup type, will be defaulted to// AUTOMATIC backup type// "AUTOMATED" - Reencrypt automatic backups// "ON_DEMAND" - Reencrypt on-demand backupsBackupTypestring `json:"backupType,omitempty"`// ForceSendFields is a list of field names (e.g. "BackupLimit") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackupLimit") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BackupReencryptionConfig: Backup Reencryption Config
func (BackupReencryptionConfig)MarshalJSON¶added inv0.128.0
func (sBackupReencryptionConfig) MarshalJSON() ([]byte,error)
typeBackupRetentionSettings¶
type BackupRetentionSettings struct {// RetainedBackups: Depending on the value of retention_unit, this is used to// determine if a backup needs to be deleted. If retention_unit is 'COUNT', we// will retain this many backups.RetainedBackupsint64 `json:"retainedBackups,omitempty"`// RetentionUnit: The unit that 'retained_backups' represents.//// Possible values:// "RETENTION_UNIT_UNSPECIFIED" - Backup retention unit is unspecified, will// be treated as COUNT.// "COUNT" - Retention will be by count, eg. "retain the most recent 7// backups".RetentionUnitstring `json:"retentionUnit,omitempty"`// ForceSendFields is a list of field names (e.g. "RetainedBackups") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "RetainedBackups") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BackupRetentionSettings: We currently only support backup retention byspecifying the number of backups we will retain.
func (BackupRetentionSettings)MarshalJSON¶
func (sBackupRetentionSettings) MarshalJSON() ([]byte,error)
typeBackupRun¶added inv0.52.0
type BackupRun struct {// BackupKind: Specifies the kind of backup, PHYSICAL or DEFAULT_SNAPSHOT.//// Possible values:// "SQL_BACKUP_KIND_UNSPECIFIED" - This is an unknown BackupKind.// "SNAPSHOT" - Snapshot-based backups.// "PHYSICAL" - Physical backups.BackupKindstring `json:"backupKind,omitempty"`// DatabaseVersion: Output only. The instance database version at the time this// backup was made.//// Possible values:// "SQL_DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version.// "MYSQL_5_1" - The database version is MySQL 5.1.// "MYSQL_5_5" - The database version is MySQL 5.5.// "MYSQL_5_6" - The database version is MySQL 5.6.// "MYSQL_5_7" - The database version is MySQL 5.7.// "MYSQL_8_0" - The database version is MySQL 8.// "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor// version is 18.// "MYSQL_8_0_26" - The database major version is MySQL 8.0 and the minor// version is 26.// "MYSQL_8_0_27" - The database major version is MySQL 8.0 and the minor// version is 27.// "MYSQL_8_0_28" - The database major version is MySQL 8.0 and the minor// version is 28.// "MYSQL_8_0_29" - The database major version is MySQL 8.0 and the minor// version is 29.// "MYSQL_8_0_30" - The database major version is MySQL 8.0 and the minor// version is 30.// "MYSQL_8_0_31" - The database major version is MySQL 8.0 and the minor// version is 31.// "MYSQL_8_0_32" - The database major version is MySQL 8.0 and the minor// version is 32.// "MYSQL_8_0_33" - The database major version is MySQL 8.0 and the minor// version is 33.// "MYSQL_8_0_34" - The database major version is MySQL 8.0 and the minor// version is 34.// "MYSQL_8_0_35" - The database major version is MySQL 8.0 and the minor// version is 35.// "MYSQL_8_0_36" - The database major version is MySQL 8.0 and the minor// version is 36.// "MYSQL_8_0_37" - The database major version is MySQL 8.0 and the minor// version is 37.// "MYSQL_8_0_39" - The database major version is MySQL 8.0 and the minor// version is 39.// "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor// version is 40.// "MYSQL_8_0_41" - The database major version is MySQL 8.0 and the minor// version is 41.// "MYSQL_8_0_42" - The database major version is MySQL 8.0 and the minor// version is 42.// "MYSQL_8_0_43" - The database major version is MySQL 8.0 and the minor// version is 43.// "MYSQL_8_0_44" - The database major version is MySQL 8.0 and the minor// version is 44.// "MYSQL_8_0_45" - The database major version is MySQL 8.0 and the minor// version is 45.// "MYSQL_8_0_46" - The database major version is MySQL 8.0 and the minor// version is 46.// "MYSQL_8_4" - The database version is MySQL 8.4.// "SQLSERVER_2017_STANDARD" - The database version is SQL Server 2017// Standard.// "SQLSERVER_2017_ENTERPRISE" - The database version is SQL Server 2017// Enterprise.// "SQLSERVER_2017_EXPRESS" - The database version is SQL Server 2017// Express.// "SQLSERVER_2017_WEB" - The database version is SQL Server 2017 Web.// "POSTGRES_9_6" - The database version is PostgreSQL 9.6.// "POSTGRES_10" - The database version is PostgreSQL 10.// "POSTGRES_11" - The database version is PostgreSQL 11.// "POSTGRES_12" - The database version is PostgreSQL 12.// "POSTGRES_13" - The database version is PostgreSQL 13.// "POSTGRES_14" - The database version is PostgreSQL 14.// "POSTGRES_15" - The database version is PostgreSQL 15.// "POSTGRES_16" - The database version is PostgreSQL 16.// "POSTGRES_17" - The database version is PostgreSQL 17.// "POSTGRES_18" - The database version is PostgreSQL 18.// "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019// Standard.// "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019// Enterprise.// "SQLSERVER_2019_EXPRESS" - The database version is SQL Server 2019// Express.// "SQLSERVER_2019_WEB" - The database version is SQL Server 2019 Web.// "SQLSERVER_2022_STANDARD" - The database version is SQL Server 2022// Standard.// "SQLSERVER_2022_ENTERPRISE" - The database version is SQL Server 2022// Enterprise.// "SQLSERVER_2022_EXPRESS" - The database version is SQL Server 2022// Express.// "SQLSERVER_2022_WEB" - The database version is SQL Server 2022 Web.DatabaseVersionstring `json:"databaseVersion,omitempty"`// Description: The description of this run, only applicable to on-demand// backups.Descriptionstring `json:"description,omitempty"`// DiskEncryptionConfiguration: Encryption configuration specific to a backup.DiskEncryptionConfiguration *DiskEncryptionConfiguration `json:"diskEncryptionConfiguration,omitempty"`// DiskEncryptionStatus: Encryption status specific to a backup.DiskEncryptionStatus *DiskEncryptionStatus `json:"diskEncryptionStatus,omitempty"`// EndTime: The time the backup operation completed in UTC timezone inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.EndTimestring `json:"endTime,omitempty"`// EnqueuedTime: The time the run was enqueued in UTC timezone inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.EnqueuedTimestring `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"`// Id: The identifier for this backup run. Unique only for a specific Cloud SQL// instance.Idint64 `json:"id,omitempty,string"`// Instance: Name of the database instance.Instancestring `json:"instance,omitempty"`// Kind: This is always `sql#backupRun`.Kindstring `json:"kind,omitempty"`// Location: Location of the backups.Locationstring `json:"location,omitempty"`// MaxChargeableBytes: Output only. The maximum chargeable bytes for the// backup.MaxChargeableBytesint64 `json:"maxChargeableBytes,omitempty,string"`// SelfLink: The URI of this resource.SelfLinkstring `json:"selfLink,omitempty"`// StartTime: The time the backup operation actually started in UTC timezone in//RFC 3339 (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.StartTimestring `json:"startTime,omitempty"`// Status: The status of this run.//// Possible values:// "SQL_BACKUP_RUN_STATUS_UNSPECIFIED" - The status of the run is unknown.// "ENQUEUED" - The backup operation was enqueued.// "OVERDUE" - The backup is overdue across a given backup window. Indicates// a problem. Example: Long-running operation in progress during the whole// window.// "RUNNING" - The backup is in progress.// "FAILED" - The backup failed.// "SUCCESSFUL" - The backup was successful.// "SKIPPED" - The backup was skipped (without problems) for a given backup// window. Example: Instance was idle.// "DELETION_PENDING" - The backup is about to be deleted.// "DELETION_FAILED" - The backup deletion failed.// "DELETED" - The backup has been deleted.Statusstring `json:"status,omitempty"`// TimeZone: Backup time zone to prevent restores to an instance with a// different time zone. Now relevant only for SQL Server.TimeZonestring `json:"timeZone,omitempty"`// Type: The type of this run; can be either "AUTOMATED" or "ON_DEMAND" or// "FINAL". This field defaults to "ON_DEMAND" and is ignored, when specified// for insert requests.//// Possible values:// "SQL_BACKUP_RUN_TYPE_UNSPECIFIED" - This is an unknown BackupRun type.// "AUTOMATED" - The backup schedule automatically triggers a backup.// "ON_DEMAND" - The user manually triggers a backup.Typestring `json:"type,omitempty"`// WindowStartTime: The start time of the backup window during which this the// backup was attempted inRFC 3339 (https://tools.ietf.org/html/rfc3339)// format, for example `2012-11-15T16:19:00.094Z`.WindowStartTimestring `json:"windowStartTime,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "BackupKind") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackupKind") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BackupRun: A BackupRun resource.
func (BackupRun)MarshalJSON¶added inv0.52.0
typeBackupRunsDeleteCall¶added inv0.52.0
type BackupRunsDeleteCall struct {// contains filtered or unexported fields}func (*BackupRunsDeleteCall)Context¶added inv0.52.0
func (c *BackupRunsDeleteCall) Context(ctxcontext.Context) *BackupRunsDeleteCall
Context sets the context to be used in this call's Do method.
func (*BackupRunsDeleteCall)Do¶added inv0.52.0
func (c *BackupRunsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.backupRuns.delete" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*BackupRunsDeleteCall)Fields¶added inv0.52.0
func (c *BackupRunsDeleteCall) Fields(s ...googleapi.Field) *BackupRunsDeleteCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupRunsDeleteCall)Header¶added inv0.52.0
func (c *BackupRunsDeleteCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeBackupRunsGetCall¶added inv0.52.0
type BackupRunsGetCall struct {// contains filtered or unexported fields}func (*BackupRunsGetCall)Context¶added inv0.52.0
func (c *BackupRunsGetCall) Context(ctxcontext.Context) *BackupRunsGetCall
Context sets the context to be used in this call's Do method.
func (*BackupRunsGetCall)Do¶added inv0.52.0
func (c *BackupRunsGetCall) Do(opts ...googleapi.CallOption) (*BackupRun,error)
Do executes the "sql.backupRuns.get" call.Any non-2xx status code is an error. Response headers are in either*BackupRun.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*BackupRunsGetCall)Fields¶added inv0.52.0
func (c *BackupRunsGetCall) Fields(s ...googleapi.Field) *BackupRunsGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupRunsGetCall)Header¶added inv0.52.0
func (c *BackupRunsGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*BackupRunsGetCall)IfNoneMatch¶added inv0.52.0
func (c *BackupRunsGetCall) IfNoneMatch(entityTagstring) *BackupRunsGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeBackupRunsInsertCall¶added inv0.52.0
type BackupRunsInsertCall struct {// contains filtered or unexported fields}func (*BackupRunsInsertCall)Context¶added inv0.52.0
func (c *BackupRunsInsertCall) Context(ctxcontext.Context) *BackupRunsInsertCall
Context sets the context to be used in this call's Do method.
func (*BackupRunsInsertCall)Do¶added inv0.52.0
func (c *BackupRunsInsertCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.backupRuns.insert" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*BackupRunsInsertCall)Fields¶added inv0.52.0
func (c *BackupRunsInsertCall) Fields(s ...googleapi.Field) *BackupRunsInsertCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupRunsInsertCall)Header¶added inv0.52.0
func (c *BackupRunsInsertCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeBackupRunsListCall¶added inv0.52.0
type BackupRunsListCall struct {// contains filtered or unexported fields}func (*BackupRunsListCall)Context¶added inv0.52.0
func (c *BackupRunsListCall) Context(ctxcontext.Context) *BackupRunsListCall
Context sets the context to be used in this call's Do method.
func (*BackupRunsListCall)Do¶added inv0.52.0
func (c *BackupRunsListCall) Do(opts ...googleapi.CallOption) (*BackupRunsListResponse,error)
Do executes the "sql.backupRuns.list" call.Any non-2xx status code is an error. Response headers are in either*BackupRunsListResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*BackupRunsListCall)Fields¶added inv0.52.0
func (c *BackupRunsListCall) Fields(s ...googleapi.Field) *BackupRunsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupRunsListCall)Header¶added inv0.52.0
func (c *BackupRunsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*BackupRunsListCall)IfNoneMatch¶added inv0.52.0
func (c *BackupRunsListCall) IfNoneMatch(entityTagstring) *BackupRunsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*BackupRunsListCall)MaxResults¶added inv0.52.0
func (c *BackupRunsListCall) MaxResults(maxResultsint64) *BackupRunsListCall
MaxResults sets the optional parameter "maxResults": Maximum number ofbackup runs per response.
func (*BackupRunsListCall)PageToken¶added inv0.52.0
func (c *BackupRunsListCall) PageToken(pageTokenstring) *BackupRunsListCall
PageToken sets the optional parameter "pageToken": A previously-returnedpage token representing part of the larger set of results to view.
func (*BackupRunsListCall)Pages¶added inv0.52.0
func (c *BackupRunsListCall) Pages(ctxcontext.Context, f func(*BackupRunsListResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeBackupRunsListResponse¶added inv0.52.0
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`.Kindstring `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.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BackupRunsListResponse: Backup run list results.
func (BackupRunsListResponse)MarshalJSON¶added inv0.52.0
func (sBackupRunsListResponse) MarshalJSON() ([]byte,error)
typeBackupRunsService¶added inv0.52.0
type BackupRunsService struct {// contains filtered or unexported fields}funcNewBackupRunsService¶added inv0.52.0
func NewBackupRunsService(s *Service) *BackupRunsService
func (*BackupRunsService)Delete¶added inv0.52.0
func (r *BackupRunsService) Delete(projectstring, instancestring, idint64) *BackupRunsDeleteCall
Delete: Deletes the backup taken by a backup run.
- id: The ID of the backup run to delete. To find a backup run ID, use thelist(https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/backupRuns/list)method.
- instance: Cloud SQL instance ID. This does not include the project ID.
- project: Project ID of the project that contains the instance.
func (*BackupRunsService)Get¶added inv0.52.0
func (r *BackupRunsService) Get(projectstring, instancestring, idint64) *BackupRunsGetCall
Get: Retrieves a resource containing information about a backup run.
- id: The ID of this backup run.- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*BackupRunsService)Insert¶added inv0.52.0
func (r *BackupRunsService) Insert(projectstring, instancestring, backuprun *BackupRun) *BackupRunsInsertCall
Insert: Creates a new backup run on demand.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*BackupRunsService)List¶added inv0.52.0
func (r *BackupRunsService) List(projectstring, instancestring) *BackupRunsListCall
List: Lists all backup runs associated with the project or a given instanceand configuration in the reverse chronological order of the backupinitiation time.
- instance: Cloud SQL instance ID, or "-" for all instances. This does notinclude the project ID.
- project: Project ID of the project that contains the instance.
typeBackupsCreateBackupCall¶added inv0.222.0
type BackupsCreateBackupCall struct {// contains filtered or unexported fields}func (*BackupsCreateBackupCall)Context¶added inv0.222.0
func (c *BackupsCreateBackupCall) Context(ctxcontext.Context) *BackupsCreateBackupCall
Context sets the context to be used in this call's Do method.
func (*BackupsCreateBackupCall)Do¶added inv0.222.0
func (c *BackupsCreateBackupCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.Backups.CreateBackup" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*BackupsCreateBackupCall)Fields¶added inv0.222.0
func (c *BackupsCreateBackupCall) Fields(s ...googleapi.Field) *BackupsCreateBackupCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupsCreateBackupCall)Header¶added inv0.222.0
func (c *BackupsCreateBackupCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeBackupsDeleteBackupCall¶added inv0.222.0
type BackupsDeleteBackupCall struct {// contains filtered or unexported fields}func (*BackupsDeleteBackupCall)Context¶added inv0.222.0
func (c *BackupsDeleteBackupCall) Context(ctxcontext.Context) *BackupsDeleteBackupCall
Context sets the context to be used in this call's Do method.
func (*BackupsDeleteBackupCall)Do¶added inv0.222.0
func (c *BackupsDeleteBackupCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.Backups.DeleteBackup" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*BackupsDeleteBackupCall)Fields¶added inv0.222.0
func (c *BackupsDeleteBackupCall) Fields(s ...googleapi.Field) *BackupsDeleteBackupCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupsDeleteBackupCall)Header¶added inv0.222.0
func (c *BackupsDeleteBackupCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeBackupsGetBackupCall¶added inv0.222.0
type BackupsGetBackupCall struct {// contains filtered or unexported fields}func (*BackupsGetBackupCall)Context¶added inv0.222.0
func (c *BackupsGetBackupCall) Context(ctxcontext.Context) *BackupsGetBackupCall
Context sets the context to be used in this call's Do method.
func (*BackupsGetBackupCall)Do¶added inv0.222.0
func (c *BackupsGetBackupCall) Do(opts ...googleapi.CallOption) (*Backup,error)
Do executes the "sql.Backups.GetBackup" call.Any non-2xx status code is an error. Response headers are in either*Backup.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*BackupsGetBackupCall)Fields¶added inv0.222.0
func (c *BackupsGetBackupCall) Fields(s ...googleapi.Field) *BackupsGetBackupCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupsGetBackupCall)Header¶added inv0.222.0
func (c *BackupsGetBackupCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*BackupsGetBackupCall)IfNoneMatch¶added inv0.222.0
func (c *BackupsGetBackupCall) IfNoneMatch(entityTagstring) *BackupsGetBackupCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeBackupsListBackupsCall¶added inv0.222.0
type BackupsListBackupsCall struct {// contains filtered or unexported fields}func (*BackupsListBackupsCall)Context¶added inv0.222.0
func (c *BackupsListBackupsCall) Context(ctxcontext.Context) *BackupsListBackupsCall
Context sets the context to be used in this call's Do method.
func (*BackupsListBackupsCall)Do¶added inv0.222.0
func (c *BackupsListBackupsCall) Do(opts ...googleapi.CallOption) (*ListBackupsResponse,error)
Do executes the "sql.Backups.ListBackups" call.Any non-2xx status code is an error. Response headers are in either*ListBackupsResponse.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*BackupsListBackupsCall)Fields¶added inv0.222.0
func (c *BackupsListBackupsCall) Fields(s ...googleapi.Field) *BackupsListBackupsCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupsListBackupsCall)Filter¶added inv0.222.0
func (c *BackupsListBackupsCall) Filter(filterstring) *BackupsListBackupsCall
Filter sets the optional parameter "filter": Multiple filter queries areseparated by spaces. For example, 'instance:abc AND type:FINAL,'location:us', 'backupInterval.startTime>=1950-01-01T01:01:25.771Z'. You canfilter by type, instance, backupInterval.startTime (creation time), orlocation.
func (*BackupsListBackupsCall)Header¶added inv0.222.0
func (c *BackupsListBackupsCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*BackupsListBackupsCall)IfNoneMatch¶added inv0.222.0
func (c *BackupsListBackupsCall) IfNoneMatch(entityTagstring) *BackupsListBackupsCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*BackupsListBackupsCall)PageSize¶added inv0.222.0
func (c *BackupsListBackupsCall) PageSize(pageSizeint64) *BackupsListBackupsCall
PageSize sets the optional parameter "pageSize": The maximum number ofbackups to return per response. The service might return fewer backups thanthis value. If a value for this parameter isn't specified, then, at most,500 backups are returned. The maximum value is 2,000. Any values that youset, which are greater than 2,000, are changed to 2,000.
func (*BackupsListBackupsCall)PageToken¶added inv0.222.0
func (c *BackupsListBackupsCall) PageToken(pageTokenstring) *BackupsListBackupsCall
PageToken sets the optional parameter "pageToken": A page token, receivedfrom a previous `ListBackups` call. Provide this to retrieve the subsequentpage. When paginating, all other parameters provided to `ListBackups` mustmatch the call that provided the page token.
func (*BackupsListBackupsCall)Pages¶added inv0.222.0
func (c *BackupsListBackupsCall) Pages(ctxcontext.Context, f func(*ListBackupsResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeBackupsService¶added inv0.222.0
type BackupsService struct {// contains filtered or unexported fields}funcNewBackupsService¶added inv0.222.0
func NewBackupsService(s *Service) *BackupsService
func (*BackupsService)CreateBackup¶added inv0.222.0
func (r *BackupsService) CreateBackup(parentstring, backup *Backup) *BackupsCreateBackupCall
CreateBackup: Creates a backup for a Cloud SQL instance. This API can beused only to create on-demand backups.
- parent: The parent resource where this backup is created. Format:projects/{project}.
func (*BackupsService)DeleteBackup¶added inv0.222.0
func (r *BackupsService) DeleteBackup(namestring) *BackupsDeleteBackupCall
DeleteBackup: Deletes the backup.
- name: The name of the backup to delete. Format:projects/{project}/backups/{backup}.
func (*BackupsService)GetBackup¶added inv0.222.0
func (r *BackupsService) GetBackup(namestring) *BackupsGetBackupCall
GetBackup: Retrieves a resource containing information about a backup.
- name: The name of the backup to retrieve. Format:projects/{project}/backups/{backup}.
func (*BackupsService)ListBackups¶added inv0.222.0
func (r *BackupsService) ListBackups(parentstring) *BackupsListBackupsCall
ListBackups: Lists all backups associated with the project.
- parent: The parent that owns this collection of backups. Format:projects/{project}.
func (*BackupsService)UpdateBackup¶added inv0.222.0
func (r *BackupsService) UpdateBackup(namestring, backup *Backup) *BackupsUpdateBackupCall
UpdateBackup: Updates the retention period and description of the backup.You can use this API to update final backups only.
- name: Output only. The resource name of the backup. Format:projects/{project}/backups/{backup}.
typeBackupsUpdateBackupCall¶added inv0.222.0
type BackupsUpdateBackupCall struct {// contains filtered or unexported fields}func (*BackupsUpdateBackupCall)Context¶added inv0.222.0
func (c *BackupsUpdateBackupCall) Context(ctxcontext.Context) *BackupsUpdateBackupCall
Context sets the context to be used in this call's Do method.
func (*BackupsUpdateBackupCall)Do¶added inv0.222.0
func (c *BackupsUpdateBackupCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.Backups.UpdateBackup" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*BackupsUpdateBackupCall)Fields¶added inv0.222.0
func (c *BackupsUpdateBackupCall) Fields(s ...googleapi.Field) *BackupsUpdateBackupCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*BackupsUpdateBackupCall)Header¶added inv0.222.0
func (c *BackupsUpdateBackupCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*BackupsUpdateBackupCall)UpdateMask¶added inv0.222.0
func (c *BackupsUpdateBackupCall) UpdateMask(updateMaskstring) *BackupsUpdateBackupCall
UpdateMask sets the optional parameter "updateMask": The list of fields thatyou can update. You can update only the description and retention period ofthe final backup.
typeBinLogCoordinates¶added inv0.52.0
type BinLogCoordinates struct {// BinLogFileName: Name of the binary log file for a Cloud SQL instance.BinLogFileNamestring `json:"binLogFileName,omitempty"`// BinLogPosition: Position (offset) within the binary log file.BinLogPositionint64 `json:"binLogPosition,omitempty,string"`// Kind: This is always `sql#binLogCoordinates`.Kindstring `json:"kind,omitempty"`// ForceSendFields is a list of field names (e.g. "BinLogFileName") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BinLogFileName") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}BinLogCoordinates: Binary log coordinates.
func (BinLogCoordinates)MarshalJSON¶added inv0.52.0
func (sBinLogCoordinates) MarshalJSON() ([]byte,error)
typeCloneContext¶added inv0.52.0
type CloneContext struct {// AllocatedIpRange: The name of the allocated ip range for the private ip// Cloud SQL instance. For example: "google-managed-services-default". If set,// the cloned instance ip will be created in the allocated range. The range// name must comply withRFC 1035 (https://tools.ietf.org/html/rfc1035).// Specifically, the name must be 1-63 characters long and match the regular// expression a-z ([-a-z0-9]*[a-z0-9])?. Reserved for future use.AllocatedIpRangestring `json:"allocatedIpRange,omitempty"`// BinLogCoordinates: Binary log coordinates, if specified, identify the// position up to which the source instance is cloned. If not specified, the// source instance is cloned up to the most recent binary log coordinates.BinLogCoordinates *BinLogCoordinates `json:"binLogCoordinates,omitempty"`// DatabaseNames: (SQL Server only) Clone only the specified databases from the// source instance. Clone all databases if empty.DatabaseNames []string `json:"databaseNames,omitempty"`// DestinationInstanceName: Required. Name of the Cloud SQL instance to be// created as a clone.DestinationInstanceNamestring `json:"destinationInstanceName,omitempty"`// Kind: This is always `sql#cloneContext`.Kindstring `json:"kind,omitempty"`// PitrTimestampMs: Reserved for future use.PitrTimestampMsint64 `json:"pitrTimestampMs,omitempty,string"`// PointInTime: Timestamp, if specified, identifies the time to which the// source instance is cloned.PointInTimestring `json:"pointInTime,omitempty"`// PreferredSecondaryZone: Optional. Copy clone and point-in-time recovery// clone of a regional instance in the specified zones. If not specified, clone// to the same secondary zone as the source instance. This value cannot be the// same as the preferred_zone field. This field applies to all DB types.PreferredSecondaryZonestring `json:"preferredSecondaryZone,omitempty"`// PreferredZone: Optional. Copy clone and point-in-time recovery clone of an// instance to the specified zone. If no zone is specified, clone to the same// primary zone as the source instance. This field applies to all DB types.PreferredZonestring `json:"preferredZone,omitempty"`// SourceInstanceDeletionTime: The timestamp used to identify the time when the// source instance is deleted. If this instance is deleted, then you must set// the timestamp.SourceInstanceDeletionTimestring `json:"sourceInstanceDeletionTime,omitempty"`// ForceSendFields is a list of field names (e.g. "AllocatedIpRange") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AllocatedIpRange") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}CloneContext: Database instance clone context.
func (CloneContext)MarshalJSON¶added inv0.52.0
func (sCloneContext) MarshalJSON() ([]byte,error)
typeColumn¶added inv0.248.0
type Column struct {// Name: Name of the column.Namestring `json:"name,omitempty"`// Type: Datatype of the column.Typestring `json:"type,omitempty"`// ForceSendFields is a list of field names (e.g. "Name") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Name") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Column: Contains the name and datatype of a column.
func (Column)MarshalJSON¶added inv0.248.0
typeConnectGenerateEphemeralCertCall¶added inv0.52.0
type ConnectGenerateEphemeralCertCall struct {// contains filtered or unexported fields}func (*ConnectGenerateEphemeralCertCall)Context¶added inv0.52.0
func (c *ConnectGenerateEphemeralCertCall) Context(ctxcontext.Context) *ConnectGenerateEphemeralCertCall
Context sets the context to be used in this call's Do method.
func (*ConnectGenerateEphemeralCertCall)Do¶added inv0.52.0
func (c *ConnectGenerateEphemeralCertCall) Do(opts ...googleapi.CallOption) (*GenerateEphemeralCertResponse,error)
Do executes the "sql.connect.generateEphemeral" call.Any non-2xx status code is an error. Response headers are in either*GenerateEphemeralCertResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*ConnectGenerateEphemeralCertCall)Fields¶added inv0.52.0
func (c *ConnectGenerateEphemeralCertCall) Fields(s ...googleapi.Field) *ConnectGenerateEphemeralCertCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ConnectGenerateEphemeralCertCall)Header¶added inv0.52.0
func (c *ConnectGenerateEphemeralCertCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeConnectGetCall¶added inv0.52.0
type ConnectGetCall struct {// contains filtered or unexported fields}func (*ConnectGetCall)Context¶added inv0.52.0
func (c *ConnectGetCall) Context(ctxcontext.Context) *ConnectGetCall
Context sets the context to be used in this call's Do method.
func (*ConnectGetCall)Do¶added inv0.52.0
func (c *ConnectGetCall) Do(opts ...googleapi.CallOption) (*ConnectSettings,error)
Do executes the "sql.connect.get" call.Any non-2xx status code is an error. Response headers are in either*ConnectSettings.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*ConnectGetCall)Fields¶added inv0.52.0
func (c *ConnectGetCall) Fields(s ...googleapi.Field) *ConnectGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ConnectGetCall)Header¶added inv0.52.0
func (c *ConnectGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ConnectGetCall)IfNoneMatch¶added inv0.52.0
func (c *ConnectGetCall) IfNoneMatch(entityTagstring) *ConnectGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*ConnectGetCall)ReadTime¶added inv0.52.0
func (c *ConnectGetCall) ReadTime(readTimestring) *ConnectGetCall
ReadTime sets the optional parameter "readTime": Optional snapshot readtimestamp to trade freshness for performance.
typeConnectPoolNodeConfig¶added inv0.227.0
type ConnectPoolNodeConfig struct {// DnsName: Output only. The DNS name of the read pool node.DnsNamestring `json:"dnsName,omitempty"`// DnsNames: Output only. The list of DNS names used by this read pool node.DnsNames []*DnsNameMapping `json:"dnsNames,omitempty"`// IpAddresses: Output only. Mappings containing IP addresses that can be used// to connect to the read pool node.IpAddresses []*IpMapping `json:"ipAddresses,omitempty"`// Name: Output only. The name of the read pool node. Doesn't include the// project ID.Namestring `json:"name,omitempty"`// ForceSendFields is a list of field names (e.g. "DnsName") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DnsName") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ConnectPoolNodeConfig: Details of a single read pool node of a read pool.
func (ConnectPoolNodeConfig)MarshalJSON¶added inv0.227.0
func (sConnectPoolNodeConfig) MarshalJSON() ([]byte,error)
typeConnectService¶added inv0.52.0
type ConnectService struct {// contains filtered or unexported fields}funcNewConnectService¶added inv0.52.0
func NewConnectService(s *Service) *ConnectService
func (*ConnectService)GenerateEphemeralCert¶added inv0.52.0
func (r *ConnectService) GenerateEphemeralCert(projectstring, instancestring, generateephemeralcertrequest *GenerateEphemeralCertRequest) *ConnectGenerateEphemeralCertCall
GenerateEphemeralCert: Generates a short-lived X509 certificate containingthe provided public key and signed by a private key specific to the targetinstance. Users may use the certificate to authenticate as themselves whenconnecting to the database.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*ConnectService)Get¶added inv0.52.0
func (r *ConnectService) Get(projectstring, instancestring) *ConnectGetCall
Get: Retrieves connect settings about a Cloud SQL instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
typeConnectSettings¶
type ConnectSettings struct {// BackendType: `SECOND_GEN`: Cloud SQL database instance. `EXTERNAL`: A// database server that is not managed by Google. This property is read-only;// use the `tier` property in the `settings` object to determine the database// type.//// Possible values:// "SQL_BACKEND_TYPE_UNSPECIFIED" - This is an unknown backend type for// instance.// "FIRST_GEN" - V1 speckle instance.// "SECOND_GEN" - V2 speckle instance.// "EXTERNAL" - On premises instance.BackendTypestring `json:"backendType,omitempty"`// CustomSubjectAlternativeNames: Custom subject alternative names for the// server certificate.CustomSubjectAlternativeNames []string `json:"customSubjectAlternativeNames,omitempty"`// DatabaseVersion: The database engine type and version. The `databaseVersion`// field cannot be changed after instance creation. MySQL instances:// `MYSQL_8_0`, `MYSQL_5_7` (default), or `MYSQL_5_6`. PostgreSQL instances:// `POSTGRES_9_6`, `POSTGRES_10`, `POSTGRES_11`, `POSTGRES_12` (default),// `POSTGRES_13`, or `POSTGRES_14`. SQL Server instances:// `SQLSERVER_2017_STANDARD` (default), `SQLSERVER_2017_ENTERPRISE`,// `SQLSERVER_2017_EXPRESS`, `SQLSERVER_2017_WEB`, `SQLSERVER_2019_STANDARD`,// `SQLSERVER_2019_ENTERPRISE`, `SQLSERVER_2019_EXPRESS`, or// `SQLSERVER_2019_WEB`.//// Possible values:// "SQL_DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version.// "MYSQL_5_1" - The database version is MySQL 5.1.// "MYSQL_5_5" - The database version is MySQL 5.5.// "MYSQL_5_6" - The database version is MySQL 5.6.// "MYSQL_5_7" - The database version is MySQL 5.7.// "MYSQL_8_0" - The database version is MySQL 8.// "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor// version is 18.// "MYSQL_8_0_26" - The database major version is MySQL 8.0 and the minor// version is 26.// "MYSQL_8_0_27" - The database major version is MySQL 8.0 and the minor// version is 27.// "MYSQL_8_0_28" - The database major version is MySQL 8.0 and the minor// version is 28.// "MYSQL_8_0_29" - The database major version is MySQL 8.0 and the minor// version is 29.// "MYSQL_8_0_30" - The database major version is MySQL 8.0 and the minor// version is 30.// "MYSQL_8_0_31" - The database major version is MySQL 8.0 and the minor// version is 31.// "MYSQL_8_0_32" - The database major version is MySQL 8.0 and the minor// version is 32.// "MYSQL_8_0_33" - The database major version is MySQL 8.0 and the minor// version is 33.// "MYSQL_8_0_34" - The database major version is MySQL 8.0 and the minor// version is 34.// "MYSQL_8_0_35" - The database major version is MySQL 8.0 and the minor// version is 35.// "MYSQL_8_0_36" - The database major version is MySQL 8.0 and the minor// version is 36.// "MYSQL_8_0_37" - The database major version is MySQL 8.0 and the minor// version is 37.// "MYSQL_8_0_39" - The database major version is MySQL 8.0 and the minor// version is 39.// "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor// version is 40.// "MYSQL_8_0_41" - The database major version is MySQL 8.0 and the minor// version is 41.// "MYSQL_8_0_42" - The database major version is MySQL 8.0 and the minor// version is 42.// "MYSQL_8_0_43" - The database major version is MySQL 8.0 and the minor// version is 43.// "MYSQL_8_0_44" - The database major version is MySQL 8.0 and the minor// version is 44.// "MYSQL_8_0_45" - The database major version is MySQL 8.0 and the minor// version is 45.// "MYSQL_8_0_46" - The database major version is MySQL 8.0 and the minor// version is 46.// "MYSQL_8_4" - The database version is MySQL 8.4.// "SQLSERVER_2017_STANDARD" - The database version is SQL Server 2017// Standard.// "SQLSERVER_2017_ENTERPRISE" - The database version is SQL Server 2017// Enterprise.// "SQLSERVER_2017_EXPRESS" - The database version is SQL Server 2017// Express.// "SQLSERVER_2017_WEB" - The database version is SQL Server 2017 Web.// "POSTGRES_9_6" - The database version is PostgreSQL 9.6.// "POSTGRES_10" - The database version is PostgreSQL 10.// "POSTGRES_11" - The database version is PostgreSQL 11.// "POSTGRES_12" - The database version is PostgreSQL 12.// "POSTGRES_13" - The database version is PostgreSQL 13.// "POSTGRES_14" - The database version is PostgreSQL 14.// "POSTGRES_15" - The database version is PostgreSQL 15.// "POSTGRES_16" - The database version is PostgreSQL 16.// "POSTGRES_17" - The database version is PostgreSQL 17.// "POSTGRES_18" - The database version is PostgreSQL 18.// "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019// Standard.// "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019// Enterprise.// "SQLSERVER_2019_EXPRESS" - The database version is SQL Server 2019// Express.// "SQLSERVER_2019_WEB" - The database version is SQL Server 2019 Web.// "SQLSERVER_2022_STANDARD" - The database version is SQL Server 2022// Standard.// "SQLSERVER_2022_ENTERPRISE" - The database version is SQL Server 2022// Enterprise.// "SQLSERVER_2022_EXPRESS" - The database version is SQL Server 2022// Express.// "SQLSERVER_2022_WEB" - The database version is SQL Server 2022 Web.DatabaseVersionstring `json:"databaseVersion,omitempty"`// DnsName: The dns name of the instance.DnsNamestring `json:"dnsName,omitempty"`// DnsNames: Output only. The list of DNS names used by this instance.DnsNames []*DnsNameMapping `json:"dnsNames,omitempty"`// IpAddresses: The assigned IP addresses for the instance.IpAddresses []*IpMapping `json:"ipAddresses,omitempty"`// Kind: This is always `sql#connectSettings`.Kindstring `json:"kind,omitempty"`// MdxProtocolSupport: Optional. Output only. mdx_protocol_support controls how// the client uses metadata exchange when connecting to the instance. The// values in the list representing parts of the MDX protocol that are supported// by this instance. When the list is empty, the instance does not support MDX,// so the client must not send an MDX request. The default is empty.//// Possible values:// "MDX_PROTOCOL_SUPPORT_UNSPECIFIED" - Not specified.// "CLIENT_PROTOCOL_TYPE" - Client should send the client protocol type in// the MDX request.MdxProtocolSupport []string `json:"mdxProtocolSupport,omitempty"`// NodeCount: The number of read pool nodes in a read pool.NodeCountint64 `json:"nodeCount,omitempty"`// Nodes: Output only. Entries containing information about each read pool node// of the read pool.Nodes []*ConnectPoolNodeConfig `json:"nodes,omitempty"`// PscEnabled: Whether PSC connectivity is enabled for this instance.PscEnabledbool `json:"pscEnabled,omitempty"`// Region: The cloud region for the instance. For example, `us-central1`,// `europe-west1`. The region cannot be changed after instance creation.Regionstring `json:"region,omitempty"`// ServerCaCert: SSL configuration.ServerCaCert *SslCert `json:"serverCaCert,omitempty"`// ServerCaMode: Specify what type of CA is used for the server certificate.//// Possible values:// "CA_MODE_UNSPECIFIED" - CA mode is unknown.// "GOOGLE_MANAGED_INTERNAL_CA" - Google-managed self-signed internal CA.// "GOOGLE_MANAGED_CAS_CA" - Google-managed regional CA part of root CA// hierarchy hosted on Google Cloud's Certificate Authority Service (CAS).// "CUSTOMER_MANAGED_CAS_CA" - Customer-managed CA hosted on Google Cloud's// Certificate Authority Service (CAS).ServerCaModestring `json:"serverCaMode,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "BackendType") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackendType") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ConnectSettings: Connect settings retrieval response.
func (ConnectSettings)MarshalJSON¶
func (sConnectSettings) MarshalJSON() ([]byte,error)
typeConnectionPoolConfig¶added inv0.227.0
type ConnectionPoolConfig struct {// ConnectionPoolingEnabled: Whether managed connection pooling is enabled.ConnectionPoolingEnabledbool `json:"connectionPoolingEnabled,omitempty"`// Flags: Optional. List of connection pool configuration flags.Flags []*ConnectionPoolFlags `json:"flags,omitempty"`// PoolerCount: Output only. Number of connection poolers.PoolerCountint64 `json:"poolerCount,omitempty"`// ForceSendFields is a list of field names (e.g. "ConnectionPoolingEnabled")// to unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ConnectionPoolingEnabled") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ConnectionPoolConfig: The managed connection pooling configuration.
func (ConnectionPoolConfig)MarshalJSON¶added inv0.227.0
func (sConnectionPoolConfig) MarshalJSON() ([]byte,error)
typeConnectionPoolFlags¶added inv0.227.0
type ConnectionPoolFlags struct {// Name: Required. The name of the flag.Namestring `json:"name,omitempty"`// Value: Required. The value of the flag. Boolean flags are set to `on` for// true and `off` for false. This field must be omitted if the flag doesn't// take a value.Valuestring `json:"value,omitempty"`// ForceSendFields is a list of field names (e.g. "Name") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Name") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ConnectionPoolFlags: Connection pool flags for Cloud SQL instances managedconnection pool configuration.
func (ConnectionPoolFlags)MarshalJSON¶added inv0.227.0
func (sConnectionPoolFlags) MarshalJSON() ([]byte,error)
typeDataCacheConfig¶added inv0.130.0
type DataCacheConfig struct {// DataCacheEnabled: Whether data cache is enabled for the instance.DataCacheEnabledbool `json:"dataCacheEnabled,omitempty"`// ForceSendFields is a list of field names (e.g. "DataCacheEnabled") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DataCacheEnabled") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DataCacheConfig: Data cache configurations.
func (DataCacheConfig)MarshalJSON¶added inv0.130.0
func (sDataCacheConfig) MarshalJSON() ([]byte,error)
typeDatabase¶added inv0.52.0
type Database struct {// Charset: The Cloud SQL charset value.Charsetstring `json:"charset,omitempty"`// Collation: The Cloud SQL collation value.Collationstring `json:"collation,omitempty"`// Etag: This field is deprecated and will be removed from a future version of// the API.Etagstring `json:"etag,omitempty"`// Instance: The name of the Cloud SQL instance. This does not include the// project ID.Instancestring `json:"instance,omitempty"`// Kind: This is always `sql#database`.Kindstring `json:"kind,omitempty"`// Name: The name of the database in the Cloud SQL instance. This does not// include the project ID or instance name.Namestring `json:"name,omitempty"`// Project: The project ID of the project containing the Cloud SQL database.// The Google apps domain is prefixed if applicable.Projectstring `json:"project,omitempty"`// SelfLink: The URI of this resource.SelfLinkstring `json:"selfLink,omitempty"`SqlserverDatabaseDetails *SqlServerDatabaseDetails `json:"sqlserverDatabaseDetails,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Charset") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Charset") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Database: Represents a SQL database on the Cloud SQL instance.
func (Database)MarshalJSON¶added inv0.52.0
typeDatabaseFlags¶
type DatabaseFlags struct {// Name: The name of the flag. These flags are passed at instance startup, so// include both server options and system variables. Flags are specified with// underscores, not hyphens. For more information, see Configuring Database// Flags (https://cloud.google.com/sql/docs/mysql/flags) in the Cloud SQL// documentation.Namestring `json:"name,omitempty"`// Value: The value of the flag. Boolean flags are set to `on` for true and// `off` for false. This field must be omitted if the flag doesn't take a// value.Valuestring `json:"value,omitempty"`// ForceSendFields is a list of field names (e.g. "Name") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Name") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DatabaseFlags: Database flags for Cloud SQL instances.
func (DatabaseFlags)MarshalJSON¶
func (sDatabaseFlags) MarshalJSON() ([]byte,error)
typeDatabaseInstance¶
type DatabaseInstance struct {// AvailableMaintenanceVersions: Output only. List all maintenance versions// applicable on the instanceAvailableMaintenanceVersions []string `json:"availableMaintenanceVersions,omitempty"`// BackendType: The backend type. `SECOND_GEN`: Cloud SQL database instance.// `EXTERNAL`: A database server that is not managed by Google. This property// is read-only; use the `tier` property in the `settings` object to determine// the database type.//// Possible values:// "SQL_BACKEND_TYPE_UNSPECIFIED" - This is an unknown backend type for// instance.// "FIRST_GEN" - V1 speckle instance.// "SECOND_GEN" - V2 speckle instance.// "EXTERNAL" - On premises instance.BackendTypestring `json:"backendType,omitempty"`// ConnectionName: Connection name of the Cloud SQL instance used in connection// strings.ConnectionNamestring `json:"connectionName,omitempty"`// CreateTime: Output only. The time when the instance was created inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.CreateTimestring `json:"createTime,omitempty"`// CurrentDiskSize: The current disk usage of the instance in bytes. This// property has been deprecated. Use the// "cloudsql.googleapis.com/database/disk/bytes_used" metric in Cloud// Monitoring API instead. Please see this announcement// (https://groups.google.com/d/msg/google-cloud-sql-announce/I_7-F9EBhT0/BtvFtdFeAgAJ)// for details.CurrentDiskSizeint64 `json:"currentDiskSize,omitempty,string"`// DatabaseInstalledVersion: Output only. Stores the current database version// running on the instance including minor version such as `MYSQL_8_0_18`.DatabaseInstalledVersionstring `json:"databaseInstalledVersion,omitempty"`// DatabaseVersion: The database engine type and version. The `databaseVersion`// field cannot be changed after instance creation.//// Possible values:// "SQL_DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version.// "MYSQL_5_1" - The database version is MySQL 5.1.// "MYSQL_5_5" - The database version is MySQL 5.5.// "MYSQL_5_6" - The database version is MySQL 5.6.// "MYSQL_5_7" - The database version is MySQL 5.7.// "MYSQL_8_0" - The database version is MySQL 8.// "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor// version is 18.// "MYSQL_8_0_26" - The database major version is MySQL 8.0 and the minor// version is 26.// "MYSQL_8_0_27" - The database major version is MySQL 8.0 and the minor// version is 27.// "MYSQL_8_0_28" - The database major version is MySQL 8.0 and the minor// version is 28.// "MYSQL_8_0_29" - The database major version is MySQL 8.0 and the minor// version is 29.// "MYSQL_8_0_30" - The database major version is MySQL 8.0 and the minor// version is 30.// "MYSQL_8_0_31" - The database major version is MySQL 8.0 and the minor// version is 31.// "MYSQL_8_0_32" - The database major version is MySQL 8.0 and the minor// version is 32.// "MYSQL_8_0_33" - The database major version is MySQL 8.0 and the minor// version is 33.// "MYSQL_8_0_34" - The database major version is MySQL 8.0 and the minor// version is 34.// "MYSQL_8_0_35" - The database major version is MySQL 8.0 and the minor// version is 35.// "MYSQL_8_0_36" - The database major version is MySQL 8.0 and the minor// version is 36.// "MYSQL_8_0_37" - The database major version is MySQL 8.0 and the minor// version is 37.// "MYSQL_8_0_39" - The database major version is MySQL 8.0 and the minor// version is 39.// "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor// version is 40.// "MYSQL_8_0_41" - The database major version is MySQL 8.0 and the minor// version is 41.// "MYSQL_8_0_42" - The database major version is MySQL 8.0 and the minor// version is 42.// "MYSQL_8_0_43" - The database major version is MySQL 8.0 and the minor// version is 43.// "MYSQL_8_0_44" - The database major version is MySQL 8.0 and the minor// version is 44.// "MYSQL_8_0_45" - The database major version is MySQL 8.0 and the minor// version is 45.// "MYSQL_8_0_46" - The database major version is MySQL 8.0 and the minor// version is 46.// "MYSQL_8_4" - The database version is MySQL 8.4.// "SQLSERVER_2017_STANDARD" - The database version is SQL Server 2017// Standard.// "SQLSERVER_2017_ENTERPRISE" - The database version is SQL Server 2017// Enterprise.// "SQLSERVER_2017_EXPRESS" - The database version is SQL Server 2017// Express.// "SQLSERVER_2017_WEB" - The database version is SQL Server 2017 Web.// "POSTGRES_9_6" - The database version is PostgreSQL 9.6.// "POSTGRES_10" - The database version is PostgreSQL 10.// "POSTGRES_11" - The database version is PostgreSQL 11.// "POSTGRES_12" - The database version is PostgreSQL 12.// "POSTGRES_13" - The database version is PostgreSQL 13.// "POSTGRES_14" - The database version is PostgreSQL 14.// "POSTGRES_15" - The database version is PostgreSQL 15.// "POSTGRES_16" - The database version is PostgreSQL 16.// "POSTGRES_17" - The database version is PostgreSQL 17.// "POSTGRES_18" - The database version is PostgreSQL 18.// "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019// Standard.// "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019// Enterprise.// "SQLSERVER_2019_EXPRESS" - The database version is SQL Server 2019// Express.// "SQLSERVER_2019_WEB" - The database version is SQL Server 2019 Web.// "SQLSERVER_2022_STANDARD" - The database version is SQL Server 2022// Standard.// "SQLSERVER_2022_ENTERPRISE" - The database version is SQL Server 2022// Enterprise.// "SQLSERVER_2022_EXPRESS" - The database version is SQL Server 2022// Express.// "SQLSERVER_2022_WEB" - The database version is SQL Server 2022 Web.DatabaseVersionstring `json:"databaseVersion,omitempty"`// DiskEncryptionConfiguration: Disk encryption configuration specific to an// instance.DiskEncryptionConfiguration *DiskEncryptionConfiguration `json:"diskEncryptionConfiguration,omitempty"`// DiskEncryptionStatus: Disk encryption status specific to an instance.DiskEncryptionStatus *DiskEncryptionStatus `json:"diskEncryptionStatus,omitempty"`// DnsName: Output only. The dns name of the instance.DnsNamestring `json:"dnsName,omitempty"`// DnsNames: Output only. The list of DNS names used by this instance.DnsNames []*DnsNameMapping `json:"dnsNames,omitempty"`// Etag: This field is deprecated and will be removed from a future version of// the API. Use the `settings.settingsVersion` field instead.Etagstring `json:"etag,omitempty"`// FailoverReplica: The name and status of the failover replica.FailoverReplica *DatabaseInstanceFailoverReplica `json:"failoverReplica,omitempty"`// GceZone: The Compute Engine zone that the instance is currently serving// from. This value could be different from the zone that was specified when// the instance was created if the instance has failed over to its secondary// zone. WARNING: Changing this might restart the instance.GceZonestring `json:"gceZone,omitempty"`// GeminiConfig: Gemini instance configuration.GeminiConfig *GeminiInstanceConfig `json:"geminiConfig,omitempty"`// IncludeReplicasForMajorVersionUpgrade: Input only. Determines whether an// in-place major version upgrade of replicas happens when an in-place major// version upgrade of a primary instance is initiated.IncludeReplicasForMajorVersionUpgradebool `json:"includeReplicasForMajorVersionUpgrade,omitempty"`// InstanceType: The instance type.//// Possible values:// "SQL_INSTANCE_TYPE_UNSPECIFIED" - This is an unknown Cloud SQL instance// type.// "CLOUD_SQL_INSTANCE" - A regular Cloud SQL instance that is not// replicating from a primary instance.// "ON_PREMISES_INSTANCE" - An instance running on the customer's premises// that is not managed by Cloud SQL.// "READ_REPLICA_INSTANCE" - A Cloud SQL instance acting as a read-replica.// "READ_POOL_INSTANCE" - A Cloud SQL read pool.InstanceTypestring `json:"instanceType,omitempty"`// IpAddresses: The assigned IP addresses for the instance.IpAddresses []*IpMapping `json:"ipAddresses,omitempty"`// Ipv6Address: The IPv6 address assigned to the instance. (Deprecated) This// property was applicable only to First Generation instances.Ipv6Addressstring `json:"ipv6Address,omitempty"`// Kind: This is always `sql#instance`.Kindstring `json:"kind,omitempty"`// MaintenanceVersion: The current software version on the instance.MaintenanceVersionstring `json:"maintenanceVersion,omitempty"`// MasterInstanceName: The name of the instance which will act as primary in// the replication setup.MasterInstanceNamestring `json:"masterInstanceName,omitempty"`// MaxDiskSize: The maximum disk size of the instance in bytes.MaxDiskSizeint64 `json:"maxDiskSize,omitempty,string"`// Name: Name of the Cloud SQL instance. This does not include the project ID.Namestring `json:"name,omitempty"`// NodeCount: The number of read pool nodes in a read pool.NodeCountint64 `json:"nodeCount,omitempty"`// Nodes: Output only. Entries containing information about each read pool node// of the read pool.Nodes []*PoolNodeConfig `json:"nodes,omitempty"`// OnPremisesConfiguration: Configuration specific to on-premises instances.OnPremisesConfiguration *OnPremisesConfiguration `json:"onPremisesConfiguration,omitempty"`// OutOfDiskReport: This field represents the report generated by the proactive// database wellness job for OutOfDisk issues. * Writers: * the proactive// database wellness job for OOD. * Readers: * the proactive database wellness// jobOutOfDiskReport *SqlOutOfDiskReport `json:"outOfDiskReport,omitempty"`// PrimaryDnsName: Output only. DEPRECATED: please use write_endpoint instead.PrimaryDnsNamestring `json:"primaryDnsName,omitempty"`// Project: The project ID of the project containing the Cloud SQL instance.// The Google apps domain is prefixed if applicable.Projectstring `json:"project,omitempty"`// PscServiceAttachmentLink: Output only. The link to service attachment of PSC// instance.PscServiceAttachmentLinkstring `json:"pscServiceAttachmentLink,omitempty"`// Region: The geographical region of the Cloud SQL instance. It can be one of// the regions (https://cloud.google.com/sql/docs/mysql/locations#location-r)// where Cloud SQL operates: For example, `asia-east1`, `europe-west1`, and// `us-central1`. The default value is `us-central1`.Regionstring `json:"region,omitempty"`// ReplicaConfiguration: Configuration specific to failover replicas and read// replicas.ReplicaConfiguration *ReplicaConfiguration `json:"replicaConfiguration,omitempty"`// ReplicaNames: The replicas of the instance.ReplicaNames []string `json:"replicaNames,omitempty"`// ReplicationCluster: Optional. A primary instance and disaster recovery (DR)// replica pair. A DR replica is a cross-region replica that you designate for// failover in the event that the primary instance experiences regional// failure. Applicable to MySQL and PostgreSQL.ReplicationCluster *ReplicationCluster `json:"replicationCluster,omitempty"`// RootPassword: Initial root password. Use only on creation. You must set root// passwords before you can connect to PostgreSQL instances.RootPasswordstring `json:"rootPassword,omitempty"`// SatisfiesPzi: Output only. This status indicates whether the instance// satisfies PZI. The status is reserved for future use.SatisfiesPzibool `json:"satisfiesPzi,omitempty"`// SatisfiesPzs: This status indicates whether the instance satisfies PZS. The// status is reserved for future use.SatisfiesPzsbool `json:"satisfiesPzs,omitempty"`// ScheduledMaintenance: The start time of any upcoming scheduled maintenance// for this instance.ScheduledMaintenance *SqlScheduledMaintenance `json:"scheduledMaintenance,omitempty"`// SecondaryGceZone: The Compute Engine zone that the failover instance is// currently serving from for a regional instance. This value could be// different from the zone that was specified when the instance was created if// the instance has failed over to its secondary/failover zone.SecondaryGceZonestring `json:"secondaryGceZone,omitempty"`// SelfLink: The URI of this resource.SelfLinkstring `json:"selfLink,omitempty"`// ServerCaCert: SSL configuration.ServerCaCert *SslCert `json:"serverCaCert,omitempty"`// ServiceAccountEmailAddress: The service account email address assigned to// the instance.\This property is read-only.ServiceAccountEmailAddressstring `json:"serviceAccountEmailAddress,omitempty"`// Settings: The user settings.Settings *Settings `json:"settings,omitempty"`// Possible values:// "SQL_NETWORK_ARCHITECTURE_UNSPECIFIED"// "NEW_NETWORK_ARCHITECTURE" - The instance uses the new network// architecture.// "OLD_NETWORK_ARCHITECTURE" - The instance uses the old network// architecture.SqlNetworkArchitecturestring `json:"sqlNetworkArchitecture,omitempty"`// State: The current serving state of the Cloud SQL instance.//// Possible values:// "SQL_INSTANCE_STATE_UNSPECIFIED" - The state of the instance is unknown.// "RUNNABLE" - The instance is running, or has been stopped by owner.// "SUSPENDED" - The instance is not available, for example due to problems// with billing.// "PENDING_DELETE" - The instance is being deleted.// "PENDING_CREATE" - The instance is being created.// "MAINTENANCE" - The instance is down for maintenance.// "FAILED" - The creation of the instance failed or a fatal error occurred// during maintenance.// "ONLINE_MAINTENANCE" - Deprecated// "REPAIRING" - (Applicable to read pool nodes only.) The read pool node// needs to be repaired. The database might be unavailable.Statestring `json:"state,omitempty"`// SuspensionReason: If the instance state is SUSPENDED, the reason for the// suspension.//// Possible values:// "SQL_SUSPENSION_REASON_UNSPECIFIED" - This is an unknown suspension// reason.// "BILLING_ISSUE" - The instance is suspended due to billing issues (for// example:, account issue)// "LEGAL_ISSUE" - The instance is suspended due to illegal content (for// example:, child pornography, copyrighted material, etc.).// "OPERATIONAL_ISSUE" - The instance is causing operational issues (for// example:, causing the database to crash).// "KMS_KEY_ISSUE" - The KMS key used by the instance is either revoked or// denied access toSuspensionReason []string `json:"suspensionReason,omitempty"`// SwitchTransactionLogsToCloudStorageEnabled: Input only. Whether Cloud SQL is// enabled to switch storing point-in-time recovery log files from a data disk// to Cloud Storage.SwitchTransactionLogsToCloudStorageEnabledbool `json:"switchTransactionLogsToCloudStorageEnabled,omitempty"`// Tags: Optional. Input only. Immutable. Tag keys and tag values that are// bound to this instance. You must represent each item in the map as: "" :// "". For example, a single resource can have the following tags: “`// "123/environment": "production", "123/costCenter": "marketing", “` For more// information on tag creation and management, see//https://cloud.google.com/resource-manager/docs/tags/tags-overview.Tags map[string]string `json:"tags,omitempty"`// UpgradableDatabaseVersions: Output only. All database versions that are// available for upgrade.UpgradableDatabaseVersions []*AvailableDatabaseVersion `json:"upgradableDatabaseVersions,omitempty"`// WriteEndpoint: Output only. The dns name of the primary instance in a// replication group.WriteEndpointstring `json:"writeEndpoint,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g.// "AvailableMaintenanceVersions") to unconditionally include in API requests.// By default, fields with empty or default values are omitted from API// requests. Seehttps://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields// for more details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AvailableMaintenanceVersions") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DatabaseInstance: A Cloud SQL instance resource.
func (DatabaseInstance)MarshalJSON¶
func (sDatabaseInstance) MarshalJSON() ([]byte,error)
typeDatabaseInstanceFailoverReplica¶
type DatabaseInstanceFailoverReplica struct {// Available: The availability status of the failover replica. A false status// indicates that the failover replica is out of sync. The primary instance can// only failover to the failover replica when the status is true.Availablebool `json:"available,omitempty"`// Name: The name of the failover replica. If specified at instance creation, a// failover replica is created for the instance. The name doesn't include the// project ID.Namestring `json:"name,omitempty"`// ForceSendFields is a list of field names (e.g. "Available") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Available") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DatabaseInstanceFailoverReplica: The name and status of the failoverreplica.
func (DatabaseInstanceFailoverReplica)MarshalJSON¶
func (sDatabaseInstanceFailoverReplica) MarshalJSON() ([]byte,error)
typeDatabasesDeleteCall¶added inv0.52.0
type DatabasesDeleteCall struct {// contains filtered or unexported fields}func (*DatabasesDeleteCall)Context¶added inv0.52.0
func (c *DatabasesDeleteCall) Context(ctxcontext.Context) *DatabasesDeleteCall
Context sets the context to be used in this call's Do method.
func (*DatabasesDeleteCall)Do¶added inv0.52.0
func (c *DatabasesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.databases.delete" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*DatabasesDeleteCall)Fields¶added inv0.52.0
func (c *DatabasesDeleteCall) Fields(s ...googleapi.Field) *DatabasesDeleteCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*DatabasesDeleteCall)Header¶added inv0.52.0
func (c *DatabasesDeleteCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeDatabasesGetCall¶added inv0.52.0
type DatabasesGetCall struct {// contains filtered or unexported fields}func (*DatabasesGetCall)Context¶added inv0.52.0
func (c *DatabasesGetCall) Context(ctxcontext.Context) *DatabasesGetCall
Context sets the context to be used in this call's Do method.
func (*DatabasesGetCall)Do¶added inv0.52.0
func (c *DatabasesGetCall) Do(opts ...googleapi.CallOption) (*Database,error)
Do executes the "sql.databases.get" call.Any non-2xx status code is an error. Response headers are in either*Database.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*DatabasesGetCall)Fields¶added inv0.52.0
func (c *DatabasesGetCall) Fields(s ...googleapi.Field) *DatabasesGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*DatabasesGetCall)Header¶added inv0.52.0
func (c *DatabasesGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*DatabasesGetCall)IfNoneMatch¶added inv0.52.0
func (c *DatabasesGetCall) IfNoneMatch(entityTagstring) *DatabasesGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeDatabasesInsertCall¶added inv0.52.0
type DatabasesInsertCall struct {// contains filtered or unexported fields}func (*DatabasesInsertCall)Context¶added inv0.52.0
func (c *DatabasesInsertCall) Context(ctxcontext.Context) *DatabasesInsertCall
Context sets the context to be used in this call's Do method.
func (*DatabasesInsertCall)Do¶added inv0.52.0
func (c *DatabasesInsertCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.databases.insert" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*DatabasesInsertCall)Fields¶added inv0.52.0
func (c *DatabasesInsertCall) Fields(s ...googleapi.Field) *DatabasesInsertCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*DatabasesInsertCall)Header¶added inv0.52.0
func (c *DatabasesInsertCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeDatabasesListCall¶added inv0.52.0
type DatabasesListCall struct {// contains filtered or unexported fields}func (*DatabasesListCall)Context¶added inv0.52.0
func (c *DatabasesListCall) Context(ctxcontext.Context) *DatabasesListCall
Context sets the context to be used in this call's Do method.
func (*DatabasesListCall)Do¶added inv0.52.0
func (c *DatabasesListCall) Do(opts ...googleapi.CallOption) (*DatabasesListResponse,error)
Do executes the "sql.databases.list" call.Any non-2xx status code is an error. Response headers are in either*DatabasesListResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*DatabasesListCall)Fields¶added inv0.52.0
func (c *DatabasesListCall) Fields(s ...googleapi.Field) *DatabasesListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*DatabasesListCall)Header¶added inv0.52.0
func (c *DatabasesListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*DatabasesListCall)IfNoneMatch¶added inv0.52.0
func (c *DatabasesListCall) IfNoneMatch(entityTagstring) *DatabasesListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeDatabasesListResponse¶added inv0.52.0
type DatabasesListResponse struct {// Items: List of database resources in the instance.Items []*Database `json:"items,omitempty"`// Kind: This is always `sql#databasesList`.Kindstring `json:"kind,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DatabasesListResponse: Database list response.
func (DatabasesListResponse)MarshalJSON¶added inv0.52.0
func (sDatabasesListResponse) MarshalJSON() ([]byte,error)
typeDatabasesPatchCall¶added inv0.52.0
type DatabasesPatchCall struct {// contains filtered or unexported fields}func (*DatabasesPatchCall)Context¶added inv0.52.0
func (c *DatabasesPatchCall) Context(ctxcontext.Context) *DatabasesPatchCall
Context sets the context to be used in this call's Do method.
func (*DatabasesPatchCall)Do¶added inv0.52.0
func (c *DatabasesPatchCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.databases.patch" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*DatabasesPatchCall)Fields¶added inv0.52.0
func (c *DatabasesPatchCall) Fields(s ...googleapi.Field) *DatabasesPatchCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*DatabasesPatchCall)Header¶added inv0.52.0
func (c *DatabasesPatchCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeDatabasesService¶added inv0.52.0
type DatabasesService struct {// contains filtered or unexported fields}funcNewDatabasesService¶added inv0.52.0
func NewDatabasesService(s *Service) *DatabasesService
func (*DatabasesService)Delete¶added inv0.52.0
func (r *DatabasesService) Delete(projectstring, instancestring, databasestring) *DatabasesDeleteCall
Delete: Deletes a database from a Cloud SQL instance.
- database: Name of the database to be deleted in the instance.- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*DatabasesService)Get¶added inv0.52.0
func (r *DatabasesService) Get(projectstring, instancestring, databasestring) *DatabasesGetCall
Get: Retrieves a resource containing information about a database inside aCloud SQL instance.
- database: Name of the database in the instance.- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*DatabasesService)Insert¶added inv0.52.0
func (r *DatabasesService) Insert(projectstring, instancestring, database *Database) *DatabasesInsertCall
Insert: Inserts a resource containing information about a database inside aCloud SQL instance. **Note:** You can't modify the default character set andcollation.
- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*DatabasesService)List¶added inv0.52.0
func (r *DatabasesService) List(projectstring, instancestring) *DatabasesListCall
List: Lists databases in the specified Cloud SQL instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*DatabasesService)Patch¶added inv0.52.0
func (r *DatabasesService) Patch(projectstring, instancestring, databasestring, database2 *Database) *DatabasesPatchCall
Patch: Partially updates a resource containing information about a databaseinside a Cloud SQL instance. This method supports patch semantics.
- database: Name of the database to be updated in the instance.- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*DatabasesService)Update¶added inv0.52.0
func (r *DatabasesService) Update(projectstring, instancestring, databasestring, database2 *Database) *DatabasesUpdateCall
Update: Updates a resource containing information about a database inside aCloud SQL instance.
- database: Name of the database to be updated in the instance.- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
typeDatabasesUpdateCall¶added inv0.52.0
type DatabasesUpdateCall struct {// contains filtered or unexported fields}func (*DatabasesUpdateCall)Context¶added inv0.52.0
func (c *DatabasesUpdateCall) Context(ctxcontext.Context) *DatabasesUpdateCall
Context sets the context to be used in this call's Do method.
func (*DatabasesUpdateCall)Do¶added inv0.52.0
func (c *DatabasesUpdateCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.databases.update" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*DatabasesUpdateCall)Fields¶added inv0.52.0
func (c *DatabasesUpdateCall) Fields(s ...googleapi.Field) *DatabasesUpdateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*DatabasesUpdateCall)Header¶added inv0.52.0
func (c *DatabasesUpdateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeDemoteContext¶added inv0.151.0
type DemoteContext struct {// Kind: This is always `sql#demoteContext`.Kindstring `json:"kind,omitempty"`// SourceRepresentativeInstanceName: Required. The name of the instance which// acts as the on-premises primary instance in the replication setup.SourceRepresentativeInstanceNamestring `json:"sourceRepresentativeInstanceName,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DemoteContext: This context is used to demote an existing standaloneinstance to be a Cloud SQL read replica for an external database server.
func (DemoteContext)MarshalJSON¶added inv0.151.0
func (sDemoteContext) MarshalJSON() ([]byte,error)
typeDemoteMasterConfiguration¶added inv0.52.0
type DemoteMasterConfiguration struct {// Kind: This is always `sql#demoteMasterConfiguration`.Kindstring `json:"kind,omitempty"`// MysqlReplicaConfiguration: MySQL specific configuration when replicating// from a MySQL on-premises primary instance. Replication configuration// information such as the username, password, certificates, and keys are not// stored in the instance metadata. The configuration information is used only// to set up the replication connection and is stored by MySQL in a file named// `master.info` in the data directory.MysqlReplicaConfiguration *DemoteMasterMySqlReplicaConfiguration `json:"mysqlReplicaConfiguration,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DemoteMasterConfiguration: Read-replica configuration for connecting to theon-premises primary instance.
func (DemoteMasterConfiguration)MarshalJSON¶added inv0.52.0
func (sDemoteMasterConfiguration) MarshalJSON() ([]byte,error)
typeDemoteMasterContext¶added inv0.52.0
type DemoteMasterContext struct {// Kind: This is always `sql#demoteMasterContext`.Kindstring `json:"kind,omitempty"`// MasterInstanceName: The name of the instance which will act as on-premises// primary instance in the replication setup.MasterInstanceNamestring `json:"masterInstanceName,omitempty"`// ReplicaConfiguration: Configuration specific to read-replicas replicating// from the on-premises primary instance.ReplicaConfiguration *DemoteMasterConfiguration `json:"replicaConfiguration,omitempty"`// SkipReplicationSetup: Flag to skip replication setup on the instance.SkipReplicationSetupbool `json:"skipReplicationSetup,omitempty"`// VerifyGtidConsistency: Verify the GTID consistency for demote operation.// Default value: `True`. Setting this flag to `false` enables you to bypass// the GTID consistency check between on-premises primary instance and Cloud// SQL instance during the demotion operation but also exposes you to the risk// of future replication failures. Change the value only if you know the reason// for the GTID divergence and are confident that doing so will not cause any// replication issues.VerifyGtidConsistencybool `json:"verifyGtidConsistency,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DemoteMasterContext: Database instance demote primary instance context.
func (DemoteMasterContext)MarshalJSON¶added inv0.52.0
func (sDemoteMasterContext) MarshalJSON() ([]byte,error)
typeDemoteMasterMySqlReplicaConfiguration¶added inv0.52.0
type DemoteMasterMySqlReplicaConfiguration struct {// CaCertificate: PEM representation of the trusted CA's x509 certificate.CaCertificatestring `json:"caCertificate,omitempty"`// ClientCertificate: PEM representation of the replica's x509 certificate.ClientCertificatestring `json:"clientCertificate,omitempty"`// ClientKey: PEM representation of the replica's private key. The// corresponding public key is encoded in the client's certificate. The format// of the replica's private key can be either PKCS #1 or PKCS #8.ClientKeystring `json:"clientKey,omitempty"`// Kind: This is always `sql#demoteMasterMysqlReplicaConfiguration`.Kindstring `json:"kind,omitempty"`// Password: The password for the replication connection.Passwordstring `json:"password,omitempty"`// Username: The username for the replication connection.Usernamestring `json:"username,omitempty"`// ForceSendFields is a list of field names (e.g. "CaCertificate") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CaCertificate") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DemoteMasterMySqlReplicaConfiguration: Read-replica configuration specificto MySQL databases.
func (DemoteMasterMySqlReplicaConfiguration)MarshalJSON¶added inv0.52.0
func (sDemoteMasterMySqlReplicaConfiguration) MarshalJSON() ([]byte,error)
typeDenyMaintenancePeriod¶
type DenyMaintenancePeriod struct {// EndDate: "deny maintenance period" end date. If the year of the end date is// empty, the year of the start date also must be empty. In this case, it means// the no maintenance interval recurs every year. The date is in format// yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01EndDatestring `json:"endDate,omitempty"`// StartDate: "deny maintenance period" start date. If the year of the start// date is empty, the year of the end date also must be empty. In this case, it// means the deny maintenance period recurs every year. The date is in format// yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01StartDatestring `json:"startDate,omitempty"`// Time: Time in UTC when the "deny maintenance period" starts on start_date// and ends on end_date. The time is in format: HH:mm:SS, i.e., 00:00:00Timestring `json:"time,omitempty"`// ForceSendFields is a list of field names (e.g. "EndDate") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "EndDate") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DenyMaintenancePeriod: Deny maintenance Periods. This specifies a date rangeduring when all CSA rollout will be denied.
func (DenyMaintenancePeriod)MarshalJSON¶
func (sDenyMaintenancePeriod) MarshalJSON() ([]byte,error)
typeDiskEncryptionConfiguration¶
type DiskEncryptionConfiguration struct {// Kind: This is always `sql#diskEncryptionConfiguration`.Kindstring `json:"kind,omitempty"`// KmsKeyName: Resource name of KMS key for disk encryptionKmsKeyNamestring `json:"kmsKeyName,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DiskEncryptionConfiguration: Disk encryption configuration for an instance.
func (DiskEncryptionConfiguration)MarshalJSON¶
func (sDiskEncryptionConfiguration) MarshalJSON() ([]byte,error)
typeDiskEncryptionStatus¶
type DiskEncryptionStatus struct {// Kind: This is always `sql#diskEncryptionStatus`.Kindstring `json:"kind,omitempty"`// KmsKeyVersionName: KMS key version used to encrypt the Cloud SQL instance// resourceKmsKeyVersionNamestring `json:"kmsKeyVersionName,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DiskEncryptionStatus: Disk encryption status for an instance.
func (DiskEncryptionStatus)MarshalJSON¶
func (sDiskEncryptionStatus) MarshalJSON() ([]byte,error)
typeDnsNameMapping¶added inv0.225.0
type DnsNameMapping struct {// ConnectionType: Output only. The connection type of the DNS name.//// Possible values:// "CONNECTION_TYPE_UNSPECIFIED" - Unknown connection type.// "PUBLIC" - Public IP.// "PRIVATE_SERVICES_ACCESS" - Private services access (private IP).// "PRIVATE_SERVICE_CONNECT" - Private Service Connect.ConnectionTypestring `json:"connectionType,omitempty"`// DnsScope: Output only. The scope that the DNS name applies to.//// Possible values:// "DNS_SCOPE_UNSPECIFIED" - Unknown DNS scope.// "INSTANCE" - Indicates a instance-level DNS name.DnsScopestring `json:"dnsScope,omitempty"`// Name: The DNS name.Namestring `json:"name,omitempty"`// ForceSendFields is a list of field names (e.g. "ConnectionType") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ConnectionType") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}DnsNameMapping: DNS metadata.
func (DnsNameMapping)MarshalJSON¶added inv0.225.0
func (sDnsNameMapping) MarshalJSON() ([]byte,error)
typeEmpty¶added inv0.126.0
type Empty struct {// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`}Empty: A generic empty message that you can re-use to avoid definingduplicated empty messages in your APIs. A typical example is to use it asthe request or the response type of an API method. For instance: service Foo{ rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
typeExecuteSqlPayload¶added inv0.248.0
type ExecuteSqlPayload struct {// AutoIamAuthn: Optional. When set to true, the API caller identity associated// with the request is used for database authentication. The API caller must be// an IAM user in the database.AutoIamAuthnbool `json:"autoIamAuthn,omitempty"`// Database: Optional. Name of the database on which the statement will be// executed.Databasestring `json:"database,omitempty"`// PartialResultMode: Optional. Controls how the API should respond when the// SQL execution result is incomplete due to the size limit or another error.// The default mode is to throw an error.//// Possible values:// "PARTIAL_RESULT_MODE_UNSPECIFIED" - Unspecified mode, effectively the same// as `FAIL_PARTIAL_RESULT`.// "FAIL_PARTIAL_RESULT" - Throw an error if the result exceeds 10 MB or if// only a partial result can be retrieved. Don't return the result.// "ALLOW_PARTIAL_RESULT" - Return a truncated result and set// `partial_result` to true if the result exceeds 10 MB or if only a partial// result can be retrieved due to error. Don't throw an error.PartialResultModestring `json:"partialResultMode,omitempty"`// RowLimit: Optional. The maximum number of rows returned per SQL statement.RowLimitint64 `json:"rowLimit,omitempty,string"`// SqlStatement: Required. SQL statements to run on the database. It can be a// single statement or a sequence of statements separated by semicolons.SqlStatementstring `json:"sqlStatement,omitempty"`// User: Optional. The name of an existing database user to connect to the// database. When `auto_iam_authn` is set to true, this field is ignored and// the API caller's IAM user is used.Userstring `json:"user,omitempty"`// ForceSendFields is a list of field names (e.g. "AutoIamAuthn") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AutoIamAuthn") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExecuteSqlPayload: The request payload used to execute SQL statements.
func (ExecuteSqlPayload)MarshalJSON¶added inv0.248.0
func (sExecuteSqlPayload) MarshalJSON() ([]byte,error)
typeExportContext¶added inv0.52.0
type ExportContext struct {// BakExportOptions: Options for exporting BAK files (SQL Server-only)BakExportOptions *ExportContextBakExportOptions `json:"bakExportOptions,omitempty"`// CsvExportOptions: Options for exporting data as CSV. `MySQL` and// `PostgreSQL` instances only.CsvExportOptions *ExportContextCsvExportOptions `json:"csvExportOptions,omitempty"`// Databases: Databases to be exported. `MySQL instances:` If `fileType` is// `SQL` and no database is specified, all databases are exported, except for// the `mysql` system database. If `fileType` is `CSV`, you can specify one// database, either by using this property or by using the// `csvExportOptions.selectQuery` property, which takes precedence over this// property. `PostgreSQL instances:` If you don't specify a database by name,// all user databases in the instance are exported. This excludes system// databases and Cloud SQL databases used to manage internal operations.// Exporting all user databases is only available for directory-formatted// parallel export. If `fileType` is `CSV`, this database must match the one// specified in the `csvExportOptions.selectQuery` property. `SQL Server// instances:` You must specify one database to be exported, and the `fileType`// must be `BAK`.Databases []string `json:"databases,omitempty"`// FileType: The file type for the specified uri.//// Possible values:// "SQL_FILE_TYPE_UNSPECIFIED" - Unknown file type.// "SQL" - File containing SQL statements.// "CSV" - File in CSV format.// "BAK"// "TDE" - TDE certificate.FileTypestring `json:"fileType,omitempty"`// Kind: This is always `sql#exportContext`.Kindstring `json:"kind,omitempty"`// Offload: Whether to perform a serverless export.Offloadbool `json:"offload,omitempty"`// SqlExportOptions: Options for exporting data as SQL statements.SqlExportOptions *ExportContextSqlExportOptions `json:"sqlExportOptions,omitempty"`// TdeExportOptions: Optional. Export parameters specific to SQL Server TDE// certificatesTdeExportOptions *ExportContextTdeExportOptions `json:"tdeExportOptions,omitempty"`// Uri: The path to the file in Google Cloud Storage where the export will be// stored. The URI is in the form `gs://bucketName/fileName`. If the file// already exists, the request succeeds, but the operation fails. If `fileType`// is `SQL` and the filename ends with .gz, the contents are compressed.Uristring `json:"uri,omitempty"`// ForceSendFields is a list of field names (e.g. "BakExportOptions") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BakExportOptions") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExportContext: Database instance export context.
func (ExportContext)MarshalJSON¶added inv0.52.0
func (sExportContext) MarshalJSON() ([]byte,error)
typeExportContextBakExportOptions¶added inv0.101.0
type ExportContextBakExportOptions struct {// BakType: Type of this bak file will be export, FULL or DIFF, SQL Server only//// Possible values:// "BAK_TYPE_UNSPECIFIED" - Default type.// "FULL" - Full backup.// "DIFF" - Differential backup.// "TLOG" - Transaction Log backupBakTypestring `json:"bakType,omitempty"`// CopyOnly: Deprecated: copy_only is deprecated. Use differential_base insteadCopyOnlybool `json:"copyOnly,omitempty"`// DifferentialBase: Whether or not the backup can be used as a differential// base copy_only backup can not be served as differential baseDifferentialBasebool `json:"differentialBase,omitempty"`// ExportLogEndTime: Optional. The end timestamp when transaction log will be// included in the export operation.RFC 3339// (https://tools.ietf.org/html/rfc3339) format (for example,// `2023-10-01T16:19:00.094`) in UTC. When omitted, all available logs until// current time will be included. Only applied to Cloud SQL for SQL Server.ExportLogEndTimestring `json:"exportLogEndTime,omitempty"`// ExportLogStartTime: Optional. The begin timestamp when transaction log will// be included in the export operation.RFC 3339// (https://tools.ietf.org/html/rfc3339) format (for example,// `2023-10-01T16:19:00.094`) in UTC. When omitted, all available logs from the// beginning of retention period will be included. Only applied to Cloud SQL// for SQL Server.ExportLogStartTimestring `json:"exportLogStartTime,omitempty"`// StripeCount: Option for specifying how many stripes to use for the export.// If blank, and the value of the striped field is true, the number of stripes// is automatically chosen.StripeCountint64 `json:"stripeCount,omitempty"`// Striped: Whether or not the export should be striped.Stripedbool `json:"striped,omitempty"`// ForceSendFields is a list of field names (e.g. "BakType") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BakType") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExportContextBakExportOptions: Options for exporting BAK files (SQLServer-only)
func (ExportContextBakExportOptions)MarshalJSON¶added inv0.101.0
func (sExportContextBakExportOptions) MarshalJSON() ([]byte,error)
typeExportContextCsvExportOptions¶added inv0.52.0
type ExportContextCsvExportOptions struct {// EscapeCharacter: Specifies the character that should appear before a data// character that needs to be escaped.EscapeCharacterstring `json:"escapeCharacter,omitempty"`// FieldsTerminatedBy: Specifies the character that separates columns within// each row (line) of the file.FieldsTerminatedBystring `json:"fieldsTerminatedBy,omitempty"`// LinesTerminatedBy: This is used to separate lines. If a line does not// contain all fields, the rest of the columns are set to their default values.LinesTerminatedBystring `json:"linesTerminatedBy,omitempty"`// QuoteCharacter: Specifies the quoting character to be used when a data value// is quoted.QuoteCharacterstring `json:"quoteCharacter,omitempty"`// SelectQuery: The select query used to extract the data.SelectQuerystring `json:"selectQuery,omitempty"`// ForceSendFields is a list of field names (e.g. "EscapeCharacter") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "EscapeCharacter") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExportContextCsvExportOptions: Options for exporting data as CSV. `MySQL`and `PostgreSQL` instances only.
func (ExportContextCsvExportOptions)MarshalJSON¶added inv0.52.0
func (sExportContextCsvExportOptions) MarshalJSON() ([]byte,error)
typeExportContextSqlExportOptions¶added inv0.52.0
type ExportContextSqlExportOptions struct {// MysqlExportOptions: Options for exporting from MySQL.MysqlExportOptions *ExportContextSqlExportOptionsMysqlExportOptions `json:"mysqlExportOptions,omitempty"`// Parallel: Optional. Whether or not the export should be parallel.Parallelbool `json:"parallel,omitempty"`// PostgresExportOptions: Options for exporting from a Cloud SQL for PostgreSQL// instance.PostgresExportOptions *ExportContextSqlExportOptionsPostgresExportOptions `json:"postgresExportOptions,omitempty"`// SchemaOnly: Export only schemas.SchemaOnlybool `json:"schemaOnly,omitempty"`// Tables: Tables to export, or that were exported, from the specified// database. If you specify tables, specify one and only one database. For// PostgreSQL instances, you can specify only one table.Tables []string `json:"tables,omitempty"`// Threads: Optional. The number of threads to use for parallel export.Threadsint64 `json:"threads,omitempty"`// ForceSendFields is a list of field names (e.g. "MysqlExportOptions") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MysqlExportOptions") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExportContextSqlExportOptions: Options for exporting data as SQL statements.
func (ExportContextSqlExportOptions)MarshalJSON¶added inv0.52.0
func (sExportContextSqlExportOptions) MarshalJSON() ([]byte,error)
typeExportContextSqlExportOptionsMysqlExportOptions¶added inv0.52.0
type ExportContextSqlExportOptionsMysqlExportOptions struct {// MasterData: Option to include SQL statement required to set up replication.// If set to `1`, the dump file includes a CHANGE MASTER TO statement with the// binary log coordinates, and --set-gtid-purged is set to ON. If set to `2`,// the CHANGE MASTER TO statement is written as a SQL comment and has no// effect. If set to any value other than `1`, --set-gtid-purged is set to OFF.MasterDataint64 `json:"masterData,omitempty"`// ForceSendFields is a list of field names (e.g. "MasterData") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MasterData") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExportContextSqlExportOptionsMysqlExportOptions: Options for exporting fromMySQL.
func (ExportContextSqlExportOptionsMysqlExportOptions)MarshalJSON¶added inv0.52.0
func (sExportContextSqlExportOptionsMysqlExportOptions) MarshalJSON() ([]byte,error)
typeExportContextSqlExportOptionsPostgresExportOptions¶added inv0.188.0
type ExportContextSqlExportOptionsPostgresExportOptions struct {// Clean: Optional. Use this option to include DROP <object> SQL statements.// Use these statements to delete database objects before running the import// operation.Cleanbool `json:"clean,omitempty"`// IfExists: Optional. Option to include an IF EXISTS SQL statement with each// DROP statement produced by clean.IfExistsbool `json:"ifExists,omitempty"`// ForceSendFields is a list of field names (e.g. "Clean") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Clean") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExportContextSqlExportOptionsPostgresExportOptions: Options for exportingfrom a Cloud SQL for PostgreSQL instance.
func (ExportContextSqlExportOptionsPostgresExportOptions)MarshalJSON¶added inv0.188.0
func (sExportContextSqlExportOptionsPostgresExportOptions) MarshalJSON() ([]byte,error)
typeExportContextTdeExportOptions¶added inv0.222.0
type ExportContextTdeExportOptions struct {// CertificatePath: Required. Path to the TDE certificate public key in the// form gs://bucketName/fileName. The instance must have write access to the// bucket. Applicable only for SQL Server instances.CertificatePathstring `json:"certificatePath,omitempty"`// Name: Required. Certificate name. Applicable only for SQL Server instances.Namestring `json:"name,omitempty"`// PrivateKeyPassword: Required. Password that encrypts the private key.PrivateKeyPasswordstring `json:"privateKeyPassword,omitempty"`// PrivateKeyPath: Required. Path to the TDE certificate private key in the// form gs://bucketName/fileName. The instance must have write access to the// location. Applicable only for SQL Server instances.PrivateKeyPathstring `json:"privateKeyPath,omitempty"`// ForceSendFields is a list of field names (e.g. "CertificatePath") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CertificatePath") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExportContextTdeExportOptions: Optional. Export parameters specific to SQLServer TDE certificates
func (ExportContextTdeExportOptions)MarshalJSON¶added inv0.222.0
func (sExportContextTdeExportOptions) MarshalJSON() ([]byte,error)
typeExternalSyncSelectedObject¶added inv0.207.0
type ExternalSyncSelectedObject struct {// Database: The name of the database that Cloud SQL migrates.Databasestring `json:"database,omitempty"`// ForceSendFields is a list of field names (e.g. "Database") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Database") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ExternalSyncSelectedObject: The selected object that Cloud SQL migrates.
func (ExternalSyncSelectedObject)MarshalJSON¶added inv0.207.0
func (sExternalSyncSelectedObject) MarshalJSON() ([]byte,error)
typeFailoverContext¶added inv0.52.0
type FailoverContext struct {// Kind: This is always `sql#failoverContext`.Kindstring `json:"kind,omitempty"`// SettingsVersion: The current settings version of this instance. Request will// be rejected if this version doesn't match the current settings version.SettingsVersionint64 `json:"settingsVersion,omitempty,string"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}FailoverContext: Database instance failover context.
func (FailoverContext)MarshalJSON¶added inv0.52.0
func (sFailoverContext) MarshalJSON() ([]byte,error)
typeFinalBackupConfig¶added inv0.248.0
type FinalBackupConfig struct {// Enabled: Whether the final backup is enabled for the instance.Enabledbool `json:"enabled,omitempty"`// RetentionDays: The number of days to retain the final backup after the// instance deletion. The final backup will be purged at// (time_of_instance_deletion + retention_days).RetentionDaysint64 `json:"retentionDays,omitempty"`// ForceSendFields is a list of field names (e.g. "Enabled") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Enabled") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}FinalBackupConfig: Config used to determine the final backup settings forthe instance.
func (FinalBackupConfig)MarshalJSON¶added inv0.248.0
func (sFinalBackupConfig) MarshalJSON() ([]byte,error)
typeFlag¶added inv0.52.0
type Flag struct {// AllowedIntValues: Use this field if only certain integers are accepted. Can// be combined with min_value and max_value to add additional values.AllowedIntValuesgoogleapi.Int64s `json:"allowedIntValues,omitempty"`// 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. Can be MySQL// instances: `MYSQL_8_0`, `MYSQL_8_0_18`, `MYSQL_8_0_26`, `MYSQL_5_7`, or// `MYSQL_5_6`. PostgreSQL instances: `POSTGRES_9_6`, `POSTGRES_10`,// `POSTGRES_11` or `POSTGRES_12`. SQL Server instances:// `SQLSERVER_2017_STANDARD`, `SQLSERVER_2017_ENTERPRISE`,// `SQLSERVER_2017_EXPRESS`, `SQLSERVER_2017_WEB`, `SQLSERVER_2019_STANDARD`,// `SQLSERVER_2019_ENTERPRISE`, `SQLSERVER_2019_EXPRESS`, or// `SQLSERVER_2019_WEB`. See the complete list// (/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion).//// Possible values:// "SQL_DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version.// "MYSQL_5_1" - The database version is MySQL 5.1.// "MYSQL_5_5" - The database version is MySQL 5.5.// "MYSQL_5_6" - The database version is MySQL 5.6.// "MYSQL_5_7" - The database version is MySQL 5.7.// "MYSQL_8_0" - The database version is MySQL 8.// "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor// version is 18.// "MYSQL_8_0_26" - The database major version is MySQL 8.0 and the minor// version is 26.// "MYSQL_8_0_27" - The database major version is MySQL 8.0 and the minor// version is 27.// "MYSQL_8_0_28" - The database major version is MySQL 8.0 and the minor// version is 28.// "MYSQL_8_0_29" - The database major version is MySQL 8.0 and the minor// version is 29.// "MYSQL_8_0_30" - The database major version is MySQL 8.0 and the minor// version is 30.// "MYSQL_8_0_31" - The database major version is MySQL 8.0 and the minor// version is 31.// "MYSQL_8_0_32" - The database major version is MySQL 8.0 and the minor// version is 32.// "MYSQL_8_0_33" - The database major version is MySQL 8.0 and the minor// version is 33.// "MYSQL_8_0_34" - The database major version is MySQL 8.0 and the minor// version is 34.// "MYSQL_8_0_35" - The database major version is MySQL 8.0 and the minor// version is 35.// "MYSQL_8_0_36" - The database major version is MySQL 8.0 and the minor// version is 36.// "MYSQL_8_0_37" - The database major version is MySQL 8.0 and the minor// version is 37.// "MYSQL_8_0_39" - The database major version is MySQL 8.0 and the minor// version is 39.// "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor// version is 40.// "MYSQL_8_0_41" - The database major version is MySQL 8.0 and the minor// version is 41.// "MYSQL_8_0_42" - The database major version is MySQL 8.0 and the minor// version is 42.// "MYSQL_8_0_43" - The database major version is MySQL 8.0 and the minor// version is 43.// "MYSQL_8_0_44" - The database major version is MySQL 8.0 and the minor// version is 44.// "MYSQL_8_0_45" - The database major version is MySQL 8.0 and the minor// version is 45.// "MYSQL_8_0_46" - The database major version is MySQL 8.0 and the minor// version is 46.// "MYSQL_8_4" - The database version is MySQL 8.4.// "SQLSERVER_2017_STANDARD" - The database version is SQL Server 2017// Standard.// "SQLSERVER_2017_ENTERPRISE" - The database version is SQL Server 2017// Enterprise.// "SQLSERVER_2017_EXPRESS" - The database version is SQL Server 2017// Express.// "SQLSERVER_2017_WEB" - The database version is SQL Server 2017 Web.// "POSTGRES_9_6" - The database version is PostgreSQL 9.6.// "POSTGRES_10" - The database version is PostgreSQL 10.// "POSTGRES_11" - The database version is PostgreSQL 11.// "POSTGRES_12" - The database version is PostgreSQL 12.// "POSTGRES_13" - The database version is PostgreSQL 13.// "POSTGRES_14" - The database version is PostgreSQL 14.// "POSTGRES_15" - The database version is PostgreSQL 15.// "POSTGRES_16" - The database version is PostgreSQL 16.// "POSTGRES_17" - The database version is PostgreSQL 17.// "POSTGRES_18" - The database version is PostgreSQL 18.// "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019// Standard.// "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019// Enterprise.// "SQLSERVER_2019_EXPRESS" - The database version is SQL Server 2019// Express.// "SQLSERVER_2019_WEB" - The database version is SQL Server 2019 Web.// "SQLSERVER_2022_STANDARD" - The database version is SQL Server 2022// Standard.// "SQLSERVER_2022_ENTERPRISE" - The database version is SQL Server 2022// Enterprise.// "SQLSERVER_2022_EXPRESS" - The database version is SQL Server 2022// Express.// "SQLSERVER_2022_WEB" - The database version is SQL Server 2022 Web.AppliesTo []string `json:"appliesTo,omitempty"`// FlagScope: Scope of flag.//// Possible values:// "SQL_FLAG_SCOPE_UNSPECIFIED" - Assume database flags if unspecified// "SQL_FLAG_SCOPE_DATABASE" - database flags// "SQL_FLAG_SCOPE_CONNECTION_POOL" - connection pool configuration flagsFlagScopestring `json:"flagScope,omitempty"`// InBeta: Whether or not the flag is considered in beta.InBetabool `json:"inBeta,omitempty"`// Kind: This is always `sql#flag`.Kindstring `json:"kind,omitempty"`// MaxValue: For `INTEGER` flags, the maximum allowed value.MaxValueint64 `json:"maxValue,omitempty,string"`// MinValue: For `INTEGER` flags, the minimum allowed value.MinValueint64 `json:"minValue,omitempty,string"`// Name: This is the name of the flag. Flag names always use underscores, not// hyphens, for example: `max_allowed_packet`Namestring `json:"name,omitempty"`// RecommendedIntValue: Recommended int value in integer format for UI display.RecommendedIntValueint64 `json:"recommendedIntValue,omitempty,string"`// RecommendedStringValue: Recommended string value in string format for UI// display.RecommendedStringValuestring `json:"recommendedStringValue,omitempty"`// RequiresRestart: Indicates whether changing this flag will trigger a// database restart. Only applicable to Second Generation instances.RequiresRestartbool `json:"requiresRestart,omitempty"`// Type: The type of the flag. Flags are typed to being `BOOLEAN`, `STRING`,// `INTEGER` or `NONE`. `NONE` is used for flags that do not take a value, such// as `skip_grant_tables`.//// Possible values:// "SQL_FLAG_TYPE_UNSPECIFIED" - This is an unknown flag type.// "BOOLEAN" - Boolean type flag.// "STRING" - String type flag.// "INTEGER" - Integer type flag.// "NONE" - Flag type used for a server startup option.// "MYSQL_TIMEZONE_OFFSET" - Type introduced specially for MySQL TimeZone// offset. Accept a string value with the format [-12:59, 13:00].// "FLOAT" - Float type flag.// "REPEATED_STRING" - Comma-separated list of the strings in a SqlFlagType// enum.Typestring `json:"type,omitempty"`// ForceSendFields is a list of field names (e.g. "AllowedIntValues") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AllowedIntValues") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Flag: A flag resource.
func (Flag)MarshalJSON¶added inv0.52.0
typeFlagsListCall¶added inv0.52.0
type FlagsListCall struct {// contains filtered or unexported fields}func (*FlagsListCall)Context¶added inv0.52.0
func (c *FlagsListCall) Context(ctxcontext.Context) *FlagsListCall
Context sets the context to be used in this call's Do method.
func (*FlagsListCall)DatabaseVersion¶added inv0.52.0
func (c *FlagsListCall) DatabaseVersion(databaseVersionstring) *FlagsListCall
DatabaseVersion sets the optional parameter "databaseVersion": Database typeand version you want to retrieve flags for. By default, this method returnsflags for all database types and versions.
func (*FlagsListCall)Do¶added inv0.52.0
func (c *FlagsListCall) Do(opts ...googleapi.CallOption) (*FlagsListResponse,error)
Do executes the "sql.flags.list" call.Any non-2xx status code is an error. Response headers are in either*FlagsListResponse.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*FlagsListCall)Fields¶added inv0.52.0
func (c *FlagsListCall) Fields(s ...googleapi.Field) *FlagsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*FlagsListCall)FlagScope¶added inv0.227.0
func (c *FlagsListCall) FlagScope(flagScopestring) *FlagsListCall
FlagScope sets the optional parameter "flagScope": Specify the scope offlags to be returned by SqlFlagsListService. Return list of database flagsif unspecified.
Possible values:
"SQL_FLAG_SCOPE_UNSPECIFIED" - Assume database flags if unspecified"SQL_FLAG_SCOPE_DATABASE" - database flags"SQL_FLAG_SCOPE_CONNECTION_POOL" - connection pool configuration flags
func (*FlagsListCall)Header¶added inv0.52.0
func (c *FlagsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*FlagsListCall)IfNoneMatch¶added inv0.52.0
func (c *FlagsListCall) IfNoneMatch(entityTagstring) *FlagsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeFlagsListResponse¶added inv0.52.0
type FlagsListResponse struct {// Items: List of flags.Items []*Flag `json:"items,omitempty"`// Kind: This is always `sql#flagsList`.Kindstring `json:"kind,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}FlagsListResponse: Flags list response.
func (FlagsListResponse)MarshalJSON¶added inv0.52.0
func (sFlagsListResponse) MarshalJSON() ([]byte,error)
typeFlagsService¶added inv0.52.0
type FlagsService struct {// contains filtered or unexported fields}funcNewFlagsService¶added inv0.52.0
func NewFlagsService(s *Service) *FlagsService
func (*FlagsService)List¶added inv0.52.0
func (r *FlagsService) List() *FlagsListCall
List: Lists all available database flags for Cloud SQL instances.
typeGeminiInstanceConfig¶added inv0.172.0
type GeminiInstanceConfig struct {// ActiveQueryEnabled: Output only. Whether the active query is enabled.ActiveQueryEnabledbool `json:"activeQueryEnabled,omitempty"`// Entitled: Output only. Whether Gemini is enabled.Entitledbool `json:"entitled,omitempty"`// FlagRecommenderEnabled: Output only. Whether the flag recommender is// enabled.FlagRecommenderEnabledbool `json:"flagRecommenderEnabled,omitempty"`// GoogleVacuumMgmtEnabled: Output only. Whether the vacuum management is// enabled.GoogleVacuumMgmtEnabledbool `json:"googleVacuumMgmtEnabled,omitempty"`// IndexAdvisorEnabled: Output only. Whether the index advisor is enabled.IndexAdvisorEnabledbool `json:"indexAdvisorEnabled,omitempty"`// OomSessionCancelEnabled: Output only. Whether canceling the out-of-memory// (OOM) session is enabled.OomSessionCancelEnabledbool `json:"oomSessionCancelEnabled,omitempty"`// ForceSendFields is a list of field names (e.g. "ActiveQueryEnabled") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ActiveQueryEnabled") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GeminiInstanceConfig: Gemini instance configuration.
func (GeminiInstanceConfig)MarshalJSON¶added inv0.172.0
func (sGeminiInstanceConfig) MarshalJSON() ([]byte,error)
typeGenerateEphemeralCertRequest¶
type GenerateEphemeralCertRequest struct {// AccessToken: Optional. Access token to include in the signed certificate.AccessTokenstring `json:"access_token,omitempty"`// PublicKey: PEM encoded public key to include in the signed certificate.PublicKeystring `json:"public_key,omitempty"`// ReadTime: Optional. Optional snapshot read timestamp to trade freshness for// performance.ReadTimestring `json:"readTime,omitempty"`// ValidDuration: Optional. If set, it will contain the cert valid duration.ValidDurationstring `json:"validDuration,omitempty"`// ForceSendFields is a list of field names (e.g. "AccessToken") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AccessToken") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateEphemeralCertRequest: Ephemeral certificate creation request.
func (GenerateEphemeralCertRequest)MarshalJSON¶
func (sGenerateEphemeralCertRequest) MarshalJSON() ([]byte,error)
typeGenerateEphemeralCertResponse¶
type GenerateEphemeralCertResponse struct {// EphemeralCert: Generated certEphemeralCert *SslCert `json:"ephemeralCert,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "EphemeralCert") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "EphemeralCert") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}GenerateEphemeralCertResponse: Ephemeral certificate creation request.
func (GenerateEphemeralCertResponse)MarshalJSON¶
func (sGenerateEphemeralCertResponse) MarshalJSON() ([]byte,error)
typeImportContext¶added inv0.52.0
type ImportContext struct {// BakImportOptions: Import parameters specific to SQL Server .BAK filesBakImportOptions *ImportContextBakImportOptions `json:"bakImportOptions,omitempty"`// CsvImportOptions: Options for importing data as CSV.CsvImportOptions *ImportContextCsvImportOptions `json:"csvImportOptions,omitempty"`// Database: The target database for the import. If `fileType` is `SQL`, this// field is required only if the import file does not specify a database, and// is overridden by any database specification in the import file. For entire// instance parallel import operations, the database is overridden by the// database name stored in subdirectory name. If `fileType` is `CSV`, one// database must be specified.Databasestring `json:"database,omitempty"`// FileType: The file type for the specified uri.\`SQL`: The file contains SQL// statements. \`CSV`: The file contains CSV data.//// Possible values:// "SQL_FILE_TYPE_UNSPECIFIED" - Unknown file type.// "SQL" - File containing SQL statements.// "CSV" - File in CSV format.// "BAK"// "TDE" - TDE certificate.FileTypestring `json:"fileType,omitempty"`// ImportUser: The PostgreSQL user for this import operation. PostgreSQL// instances only.ImportUserstring `json:"importUser,omitempty"`// Kind: This is always `sql#importContext`.Kindstring `json:"kind,omitempty"`// SqlImportOptions: Optional. Options for importing data from SQL statements.SqlImportOptions *ImportContextSqlImportOptions `json:"sqlImportOptions,omitempty"`// TdeImportOptions: Optional. Import parameters specific to SQL Server TDE// certificatesTdeImportOptions *ImportContextTdeImportOptions `json:"tdeImportOptions,omitempty"`// Uri: Path to the import file in Cloud Storage, in the form// `gs://bucketName/fileName`. Compressed gzip files (.gz) are supported when// `fileType` is `SQL`. The instance must have write permissions to the bucket// and read access to the file.Uristring `json:"uri,omitempty"`// ForceSendFields is a list of field names (e.g. "BakImportOptions") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BakImportOptions") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ImportContext: Database instance import context.
func (ImportContext)MarshalJSON¶added inv0.52.0
func (sImportContext) MarshalJSON() ([]byte,error)
typeImportContextBakImportOptions¶added inv0.52.0
type ImportContextBakImportOptions struct {// BakType: Type of the bak content, FULL or DIFF//// Possible values:// "BAK_TYPE_UNSPECIFIED" - Default type.// "FULL" - Full backup.// "DIFF" - Differential backup.// "TLOG" - Transaction Log backupBakTypestring `json:"bakType,omitempty"`EncryptionOptions *ImportContextBakImportOptionsEncryptionOptions `json:"encryptionOptions,omitempty"`// NoRecovery: Whether or not the backup importing will restore database with// NORECOVERY option. Applies only to Cloud SQL for SQL Server.NoRecoverybool `json:"noRecovery,omitempty"`// RecoveryOnly: Whether or not the backup importing request will just bring// database online without downloading Bak content only one of "no_recovery"// and "recovery_only" can be true otherwise error will return. Applies only to// Cloud SQL for SQL Server.RecoveryOnlybool `json:"recoveryOnly,omitempty"`// StopAt: Optional. The timestamp when the import should stop. This timestamp// is in theRFC 3339 (https://tools.ietf.org/html/rfc3339) format (for// example, `2023-10-01T16:19:00.094`). This field is equivalent to the STOPAT// keyword and applies to Cloud SQL for SQL Server only.StopAtstring `json:"stopAt,omitempty"`// StopAtMark: Optional. The marked transaction where the import should stop.// This field is equivalent to the STOPATMARK keyword and applies to Cloud SQL// for SQL Server only.StopAtMarkstring `json:"stopAtMark,omitempty"`// Striped: Whether or not the backup set being restored is striped. Applies// only to Cloud SQL for SQL Server.Stripedbool `json:"striped,omitempty"`// ForceSendFields is a list of field names (e.g. "BakType") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BakType") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ImportContextBakImportOptions: Import parameters specific to SQL Server .BAKfiles
func (ImportContextBakImportOptions)MarshalJSON¶added inv0.52.0
func (sImportContextBakImportOptions) MarshalJSON() ([]byte,error)
typeImportContextBakImportOptionsEncryptionOptions¶added inv0.52.0
type ImportContextBakImportOptionsEncryptionOptions struct {// CertPath: Path to the Certificate (.cer) in Cloud Storage, in the form// `gs://bucketName/fileName`. The instance must have write permissions to the// bucket and read access to the file.CertPathstring `json:"certPath,omitempty"`// KeepEncrypted: Optional. Whether the imported file remains encrypted.KeepEncryptedbool `json:"keepEncrypted,omitempty"`// PvkPassword: Password that encrypts the private keyPvkPasswordstring `json:"pvkPassword,omitempty"`// PvkPath: Path to the Certificate Private Key (.pvk) in Cloud Storage, in the// form `gs://bucketName/fileName`. The instance must have write permissions to// the bucket and read access to the file.PvkPathstring `json:"pvkPath,omitempty"`// ForceSendFields is a list of field names (e.g. "CertPath") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CertPath") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}func (ImportContextBakImportOptionsEncryptionOptions)MarshalJSON¶added inv0.52.0
func (sImportContextBakImportOptionsEncryptionOptions) MarshalJSON() ([]byte,error)
typeImportContextCsvImportOptions¶added inv0.52.0
type ImportContextCsvImportOptions struct {// Columns: The columns to which CSV data is imported. If not specified, all// columns of the database table are loaded with CSV data.Columns []string `json:"columns,omitempty"`// EscapeCharacter: Specifies the character that should appear before a data// character that needs to be escaped.EscapeCharacterstring `json:"escapeCharacter,omitempty"`// FieldsTerminatedBy: Specifies the character that separates columns within// each row (line) of the file.FieldsTerminatedBystring `json:"fieldsTerminatedBy,omitempty"`// LinesTerminatedBy: This is used to separate lines. If a line does not// contain all fields, the rest of the columns are set to their default values.LinesTerminatedBystring `json:"linesTerminatedBy,omitempty"`// QuoteCharacter: Specifies the quoting character to be used when a data value// is quoted.QuoteCharacterstring `json:"quoteCharacter,omitempty"`// Table: The table to which CSV data is imported.Tablestring `json:"table,omitempty"`// ForceSendFields is a list of field names (e.g. "Columns") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Columns") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ImportContextCsvImportOptions: Options for importing data as CSV.
func (ImportContextCsvImportOptions)MarshalJSON¶added inv0.52.0
func (sImportContextCsvImportOptions) MarshalJSON() ([]byte,error)
typeImportContextSqlImportOptions¶added inv0.173.0
type ImportContextSqlImportOptions struct {// Parallel: Optional. Whether or not the import should be parallel.Parallelbool `json:"parallel,omitempty"`// PostgresImportOptions: Optional. Options for importing from a Cloud SQL for// PostgreSQL instance.PostgresImportOptions *ImportContextSqlImportOptionsPostgresImportOptions `json:"postgresImportOptions,omitempty"`// Threads: Optional. The number of threads to use for parallel import.Threadsint64 `json:"threads,omitempty"`// ForceSendFields is a list of field names (e.g. "Parallel") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Parallel") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ImportContextSqlImportOptions: Optional. Options for importing data from SQLstatements.
func (ImportContextSqlImportOptions)MarshalJSON¶added inv0.173.0
func (sImportContextSqlImportOptions) MarshalJSON() ([]byte,error)
typeImportContextSqlImportOptionsPostgresImportOptions¶added inv0.188.0
type ImportContextSqlImportOptionsPostgresImportOptions struct {// Clean: Optional. The --clean flag for the pg_restore utility. This flag// applies only if you enabled Cloud SQL to import files in parallel.Cleanbool `json:"clean,omitempty"`// IfExists: Optional. The --if-exists flag for the pg_restore utility. This// flag applies only if you enabled Cloud SQL to import files in parallel.IfExistsbool `json:"ifExists,omitempty"`// ForceSendFields is a list of field names (e.g. "Clean") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Clean") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ImportContextSqlImportOptionsPostgresImportOptions: Optional. Options forimporting from a Cloud SQL for PostgreSQL instance.
func (ImportContextSqlImportOptionsPostgresImportOptions)MarshalJSON¶added inv0.188.0
func (sImportContextSqlImportOptionsPostgresImportOptions) MarshalJSON() ([]byte,error)
typeImportContextTdeImportOptions¶added inv0.222.0
type ImportContextTdeImportOptions struct {// CertificatePath: Required. Path to the TDE certificate public key in the// form gs://bucketName/fileName. The instance must have read access to the// file. Applicable only for SQL Server instances.CertificatePathstring `json:"certificatePath,omitempty"`// Name: Required. Certificate name. Applicable only for SQL Server instances.Namestring `json:"name,omitempty"`// PrivateKeyPassword: Required. Password that encrypts the private key.PrivateKeyPasswordstring `json:"privateKeyPassword,omitempty"`// PrivateKeyPath: Required. Path to the TDE certificate private key in the// form gs://bucketName/fileName. The instance must have read access to the// file. Applicable only for SQL Server instances.PrivateKeyPathstring `json:"privateKeyPath,omitempty"`// ForceSendFields is a list of field names (e.g. "CertificatePath") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CertificatePath") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ImportContextTdeImportOptions: Optional. Import parameters specific to SQLServer TDE certificates
func (ImportContextTdeImportOptions)MarshalJSON¶added inv0.222.0
func (sImportContextTdeImportOptions) MarshalJSON() ([]byte,error)
typeInsightsConfig¶
type InsightsConfig struct {// QueryInsightsEnabled: Whether Query Insights feature is enabled.QueryInsightsEnabledbool `json:"queryInsightsEnabled,omitempty"`// QueryPlansPerMinute: Number of query execution plans captured by Insights// per minute for all queries combined. Default is 5.QueryPlansPerMinuteint64 `json:"queryPlansPerMinute,omitempty"`// QueryStringLength: Maximum query length stored in bytes. Default value: 1024// bytes. Range: 256-4500 bytes. Query lengths greater than this field value// will be truncated to this value. When unset, query length will be the// default value. Changing query length will restart the database.QueryStringLengthint64 `json:"queryStringLength,omitempty"`// RecordApplicationTags: Whether Query Insights will record application tags// from query when enabled.RecordApplicationTagsbool `json:"recordApplicationTags,omitempty"`// RecordClientAddress: Whether Query Insights will record client address when// enabled.RecordClientAddressbool `json:"recordClientAddress,omitempty"`// ForceSendFields is a list of field names (e.g. "QueryInsightsEnabled") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "QueryInsightsEnabled") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InsightsConfig: Insights configuration. This specifies when Cloud SQLInsights feature is enabled and optional configuration.
func (InsightsConfig)MarshalJSON¶
func (sInsightsConfig) MarshalJSON() ([]byte,error)
typeInstanceReference¶
type InstanceReference struct {// Name: The name of the Cloud SQL instance being referenced. This does not// include the project ID.Namestring `json:"name,omitempty"`// Project: The project ID of the Cloud SQL instance being referenced. The// default is the same project ID as the instance references it.Projectstring `json:"project,omitempty"`// Region: The region of the Cloud SQL instance being referenced.Regionstring `json:"region,omitempty"`// ForceSendFields is a list of field names (e.g. "Name") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Name") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstanceReference: Reference to another Cloud SQL instance.
func (InstanceReference)MarshalJSON¶
func (sInstanceReference) MarshalJSON() ([]byte,error)
typeInstancesAcquireSsrsLeaseCall¶added inv0.170.0
type InstancesAcquireSsrsLeaseCall struct {// contains filtered or unexported fields}func (*InstancesAcquireSsrsLeaseCall)Context¶added inv0.170.0
func (c *InstancesAcquireSsrsLeaseCall) Context(ctxcontext.Context) *InstancesAcquireSsrsLeaseCall
Context sets the context to be used in this call's Do method.
func (*InstancesAcquireSsrsLeaseCall)Do¶added inv0.170.0
func (c *InstancesAcquireSsrsLeaseCall) Do(opts ...googleapi.CallOption) (*SqlInstancesAcquireSsrsLeaseResponse,error)
Do executes the "sql.instances.acquireSsrsLease" call.Any non-2xx status code is an error. Response headers are in either*SqlInstancesAcquireSsrsLeaseResponse.ServerResponse.Header or (if aresponse was returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*InstancesAcquireSsrsLeaseCall)Fields¶added inv0.170.0
func (c *InstancesAcquireSsrsLeaseCall) Fields(s ...googleapi.Field) *InstancesAcquireSsrsLeaseCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesAcquireSsrsLeaseCall)Header¶added inv0.170.0
func (c *InstancesAcquireSsrsLeaseCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesAcquireSsrsLeaseRequest¶added inv0.170.0
type InstancesAcquireSsrsLeaseRequest struct {// AcquireSsrsLeaseContext: Contains details about the acquire SSRS lease// operation.AcquireSsrsLeaseContext *AcquireSsrsLeaseContext `json:"acquireSsrsLeaseContext,omitempty"`// ForceSendFields is a list of field names (e.g. "AcquireSsrsLeaseContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AcquireSsrsLeaseContext") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesAcquireSsrsLeaseRequest: Request to acquire a lease for SSRS.
func (InstancesAcquireSsrsLeaseRequest)MarshalJSON¶added inv0.170.0
func (sInstancesAcquireSsrsLeaseRequest) MarshalJSON() ([]byte,error)
typeInstancesAddServerCaCall¶added inv0.52.0
type InstancesAddServerCaCall struct {// contains filtered or unexported fields}func (*InstancesAddServerCaCall)Context¶added inv0.52.0
func (c *InstancesAddServerCaCall) Context(ctxcontext.Context) *InstancesAddServerCaCall
Context sets the context to be used in this call's Do method.
func (*InstancesAddServerCaCall)Do¶added inv0.52.0
func (c *InstancesAddServerCaCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.addServerCa" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesAddServerCaCall)Fields¶added inv0.52.0
func (c *InstancesAddServerCaCall) Fields(s ...googleapi.Field) *InstancesAddServerCaCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesAddServerCaCall)Header¶added inv0.52.0
func (c *InstancesAddServerCaCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesAddServerCertificateCall¶added inv0.197.0
type InstancesAddServerCertificateCall struct {// contains filtered or unexported fields}func (*InstancesAddServerCertificateCall)Context¶added inv0.197.0
func (c *InstancesAddServerCertificateCall) Context(ctxcontext.Context) *InstancesAddServerCertificateCall
Context sets the context to be used in this call's Do method.
func (*InstancesAddServerCertificateCall)Do¶added inv0.197.0
func (c *InstancesAddServerCertificateCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.addServerCertificate" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesAddServerCertificateCall)Fields¶added inv0.197.0
func (c *InstancesAddServerCertificateCall) Fields(s ...googleapi.Field) *InstancesAddServerCertificateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesAddServerCertificateCall)Header¶added inv0.197.0
func (c *InstancesAddServerCertificateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesCloneCall¶added inv0.52.0
type InstancesCloneCall struct {// contains filtered or unexported fields}func (*InstancesCloneCall)Context¶added inv0.52.0
func (c *InstancesCloneCall) Context(ctxcontext.Context) *InstancesCloneCall
Context sets the context to be used in this call's Do method.
func (*InstancesCloneCall)Do¶added inv0.52.0
func (c *InstancesCloneCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.clone" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesCloneCall)Fields¶added inv0.52.0
func (c *InstancesCloneCall) Fields(s ...googleapi.Field) *InstancesCloneCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesCloneCall)Header¶added inv0.52.0
func (c *InstancesCloneCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesCloneRequest¶added inv0.52.0
type InstancesCloneRequest struct {// CloneContext: Required. Contains details about the clone operation.CloneContext *CloneContext `json:"cloneContext,omitempty"`// ForceSendFields is a list of field names (e.g. "CloneContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CloneContext") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesCloneRequest: Database instance clone request.
func (InstancesCloneRequest)MarshalJSON¶added inv0.52.0
func (sInstancesCloneRequest) MarshalJSON() ([]byte,error)
typeInstancesDeleteCall¶added inv0.52.0
type InstancesDeleteCall struct {// contains filtered or unexported fields}func (*InstancesDeleteCall)Context¶added inv0.52.0
func (c *InstancesDeleteCall) Context(ctxcontext.Context) *InstancesDeleteCall
Context sets the context to be used in this call's Do method.
func (*InstancesDeleteCall)Do¶added inv0.52.0
func (c *InstancesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.delete" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesDeleteCall)EnableFinalBackup¶added inv0.200.0
func (c *InstancesDeleteCall) EnableFinalBackup(enableFinalBackupbool) *InstancesDeleteCall
EnableFinalBackup sets the optional parameter "enableFinalBackup": Flag toopt-in for final backup. By default, it is turned off.
func (*InstancesDeleteCall)Fields¶added inv0.52.0
func (c *InstancesDeleteCall) Fields(s ...googleapi.Field) *InstancesDeleteCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesDeleteCall)FinalBackupDescription¶added inv0.200.0
func (c *InstancesDeleteCall) FinalBackupDescription(finalBackupDescriptionstring) *InstancesDeleteCall
FinalBackupDescription sets the optional parameter "finalBackupDescription":The description of the final backup.
func (*InstancesDeleteCall)FinalBackupExpiryTime¶added inv0.200.0
func (c *InstancesDeleteCall) FinalBackupExpiryTime(finalBackupExpiryTimestring) *InstancesDeleteCall
FinalBackupExpiryTime sets the optional parameter "finalBackupExpiryTime":Final Backup expiration time. Timestamp in UTC of when this resource isconsidered expired.
func (*InstancesDeleteCall)FinalBackupTtlDays¶added inv0.200.0
func (c *InstancesDeleteCall) FinalBackupTtlDays(finalBackupTtlDaysint64) *InstancesDeleteCall
FinalBackupTtlDays sets the optional parameter "finalBackupTtlDays":Retention period of the final backup.
func (*InstancesDeleteCall)Header¶added inv0.52.0
func (c *InstancesDeleteCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesDemoteCall¶added inv0.151.0
type InstancesDemoteCall struct {// contains filtered or unexported fields}func (*InstancesDemoteCall)Context¶added inv0.151.0
func (c *InstancesDemoteCall) Context(ctxcontext.Context) *InstancesDemoteCall
Context sets the context to be used in this call's Do method.
func (*InstancesDemoteCall)Do¶added inv0.151.0
func (c *InstancesDemoteCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.demote" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesDemoteCall)Fields¶added inv0.151.0
func (c *InstancesDemoteCall) Fields(s ...googleapi.Field) *InstancesDemoteCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesDemoteCall)Header¶added inv0.151.0
func (c *InstancesDemoteCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesDemoteMasterCall¶added inv0.52.0
type InstancesDemoteMasterCall struct {// contains filtered or unexported fields}func (*InstancesDemoteMasterCall)Context¶added inv0.52.0
func (c *InstancesDemoteMasterCall) Context(ctxcontext.Context) *InstancesDemoteMasterCall
Context sets the context to be used in this call's Do method.
func (*InstancesDemoteMasterCall)Do¶added inv0.52.0
func (c *InstancesDemoteMasterCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.demoteMaster" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesDemoteMasterCall)Fields¶added inv0.52.0
func (c *InstancesDemoteMasterCall) Fields(s ...googleapi.Field) *InstancesDemoteMasterCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesDemoteMasterCall)Header¶added inv0.52.0
func (c *InstancesDemoteMasterCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesDemoteMasterRequest¶added inv0.52.0
type InstancesDemoteMasterRequest struct {// DemoteMasterContext: Contains details about the demoteMaster operation.DemoteMasterContext *DemoteMasterContext `json:"demoteMasterContext,omitempty"`// ForceSendFields is a list of field names (e.g. "DemoteMasterContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DemoteMasterContext") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesDemoteMasterRequest: Database demote primary instance request.
func (InstancesDemoteMasterRequest)MarshalJSON¶added inv0.52.0
func (sInstancesDemoteMasterRequest) MarshalJSON() ([]byte,error)
typeInstancesDemoteRequest¶added inv0.151.0
type InstancesDemoteRequest struct {// DemoteContext: Required. Contains details about the demote operation.DemoteContext *DemoteContext `json:"demoteContext,omitempty"`// ForceSendFields is a list of field names (e.g. "DemoteContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DemoteContext") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesDemoteRequest: This request is used to demote an existingstandalone instance to be a Cloud SQL read replica for an external databaseserver.
func (InstancesDemoteRequest)MarshalJSON¶added inv0.151.0
func (sInstancesDemoteRequest) MarshalJSON() ([]byte,error)
typeInstancesExecuteSqlCall¶added inv0.248.0
type InstancesExecuteSqlCall struct {// contains filtered or unexported fields}func (*InstancesExecuteSqlCall)Context¶added inv0.248.0
func (c *InstancesExecuteSqlCall) Context(ctxcontext.Context) *InstancesExecuteSqlCall
Context sets the context to be used in this call's Do method.
func (*InstancesExecuteSqlCall)Do¶added inv0.248.0
func (c *InstancesExecuteSqlCall) Do(opts ...googleapi.CallOption) (*SqlInstancesExecuteSqlResponse,error)
Do executes the "sql.instances.executeSql" call.Any non-2xx status code is an error. Response headers are in either*SqlInstancesExecuteSqlResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*InstancesExecuteSqlCall)Fields¶added inv0.248.0
func (c *InstancesExecuteSqlCall) Fields(s ...googleapi.Field) *InstancesExecuteSqlCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesExecuteSqlCall)Header¶added inv0.248.0
func (c *InstancesExecuteSqlCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesExportCall¶added inv0.52.0
type InstancesExportCall struct {// contains filtered or unexported fields}func (*InstancesExportCall)Context¶added inv0.52.0
func (c *InstancesExportCall) Context(ctxcontext.Context) *InstancesExportCall
Context sets the context to be used in this call's Do method.
func (*InstancesExportCall)Do¶added inv0.52.0
func (c *InstancesExportCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.export" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesExportCall)Fields¶added inv0.52.0
func (c *InstancesExportCall) Fields(s ...googleapi.Field) *InstancesExportCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesExportCall)Header¶added inv0.52.0
func (c *InstancesExportCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesExportRequest¶added inv0.52.0
type InstancesExportRequest struct {// ExportContext: Contains details about the export operation.ExportContext *ExportContext `json:"exportContext,omitempty"`// ForceSendFields is a list of field names (e.g. "ExportContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ExportContext") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesExportRequest: Database instance export request.
func (InstancesExportRequest)MarshalJSON¶added inv0.52.0
func (sInstancesExportRequest) MarshalJSON() ([]byte,error)
typeInstancesFailoverCall¶added inv0.52.0
type InstancesFailoverCall struct {// contains filtered or unexported fields}func (*InstancesFailoverCall)Context¶added inv0.52.0
func (c *InstancesFailoverCall) Context(ctxcontext.Context) *InstancesFailoverCall
Context sets the context to be used in this call's Do method.
func (*InstancesFailoverCall)Do¶added inv0.52.0
func (c *InstancesFailoverCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.failover" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesFailoverCall)Fields¶added inv0.52.0
func (c *InstancesFailoverCall) Fields(s ...googleapi.Field) *InstancesFailoverCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesFailoverCall)Header¶added inv0.52.0
func (c *InstancesFailoverCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesFailoverRequest¶added inv0.52.0
type InstancesFailoverRequest struct {// FailoverContext: Failover Context.FailoverContext *FailoverContext `json:"failoverContext,omitempty"`// ForceSendFields is a list of field names (e.g. "FailoverContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "FailoverContext") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesFailoverRequest: Instance failover request.
func (InstancesFailoverRequest)MarshalJSON¶added inv0.52.0
func (sInstancesFailoverRequest) MarshalJSON() ([]byte,error)
typeInstancesGetCall¶added inv0.52.0
type InstancesGetCall struct {// contains filtered or unexported fields}func (*InstancesGetCall)Context¶added inv0.52.0
func (c *InstancesGetCall) Context(ctxcontext.Context) *InstancesGetCall
Context sets the context to be used in this call's Do method.
func (*InstancesGetCall)Do¶added inv0.52.0
func (c *InstancesGetCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance,error)
Do executes the "sql.instances.get" call.Any non-2xx status code is an error. Response headers are in either*DatabaseInstance.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*InstancesGetCall)Fields¶added inv0.52.0
func (c *InstancesGetCall) Fields(s ...googleapi.Field) *InstancesGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesGetCall)Header¶added inv0.52.0
func (c *InstancesGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*InstancesGetCall)IfNoneMatch¶added inv0.52.0
func (c *InstancesGetCall) IfNoneMatch(entityTagstring) *InstancesGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeInstancesImportCall¶added inv0.52.0
type InstancesImportCall struct {// contains filtered or unexported fields}func (*InstancesImportCall)Context¶added inv0.52.0
func (c *InstancesImportCall) Context(ctxcontext.Context) *InstancesImportCall
Context sets the context to be used in this call's Do method.
func (*InstancesImportCall)Do¶added inv0.52.0
func (c *InstancesImportCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.import" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesImportCall)Fields¶added inv0.52.0
func (c *InstancesImportCall) Fields(s ...googleapi.Field) *InstancesImportCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesImportCall)Header¶added inv0.52.0
func (c *InstancesImportCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesImportRequest¶added inv0.52.0
type InstancesImportRequest struct {// ImportContext: Contains details about the import operation.ImportContext *ImportContext `json:"importContext,omitempty"`// ForceSendFields is a list of field names (e.g. "ImportContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ImportContext") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesImportRequest: Database instance import request.
func (InstancesImportRequest)MarshalJSON¶added inv0.52.0
func (sInstancesImportRequest) MarshalJSON() ([]byte,error)
typeInstancesInsertCall¶added inv0.52.0
type InstancesInsertCall struct {// contains filtered or unexported fields}func (*InstancesInsertCall)Context¶added inv0.52.0
func (c *InstancesInsertCall) Context(ctxcontext.Context) *InstancesInsertCall
Context sets the context to be used in this call's Do method.
func (*InstancesInsertCall)Do¶added inv0.52.0
func (c *InstancesInsertCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.insert" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesInsertCall)Fields¶added inv0.52.0
func (c *InstancesInsertCall) Fields(s ...googleapi.Field) *InstancesInsertCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesInsertCall)Header¶added inv0.52.0
func (c *InstancesInsertCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesListCall¶
type InstancesListCall struct {// contains filtered or unexported fields}func (*InstancesListCall)Context¶
func (c *InstancesListCall) Context(ctxcontext.Context) *InstancesListCall
Context sets the context to be used in this call's Do method.
func (*InstancesListCall)Do¶
func (c *InstancesListCall) Do(opts ...googleapi.CallOption) (*InstancesListResponse,error)
Do executes the "sql.instances.list" call.Any non-2xx status code is an error. Response headers are in either*InstancesListResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*InstancesListCall)Fields¶
func (c *InstancesListCall) Fields(s ...googleapi.Field) *InstancesListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesListCall)Filter¶
func (c *InstancesListCall) Filter(filterstring) *InstancesListCall
Filter sets the optional parameter "filter": A filter expression thatfilters resources listed in the response. The expression is in the form offield:value. For example, 'instanceType:CLOUD_SQL_INSTANCE'. Fields can benested as needed as per their JSON representation, such as'settings.userLabels.auto_start:true'. Multiple filter queries arespace-separated. For example. 'state:RUNNABLEinstanceType:CLOUD_SQL_INSTANCE'. By default, each expression is an ANDexpression. However, you can include AND and OR expressions explicitly.
func (*InstancesListCall)Header¶
func (c *InstancesListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*InstancesListCall)IfNoneMatch¶
func (c *InstancesListCall) IfNoneMatch(entityTagstring) *InstancesListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*InstancesListCall)MaxResults¶
func (c *InstancesListCall) MaxResults(maxResultsint64) *InstancesListCall
MaxResults sets the optional parameter "maxResults": The maximum number ofinstances to return. The service may return fewer than this value. Ifunspecified, at most 500 instances are returned. The maximum value is 1000;values above 1000 are coerced to 1000.
func (*InstancesListCall)PageToken¶
func (c *InstancesListCall) PageToken(pageTokenstring) *InstancesListCall
PageToken sets the optional parameter "pageToken": A previously-returnedpage token representing part of the larger set of results to view.
func (*InstancesListCall)Pages¶
func (c *InstancesListCall) Pages(ctxcontext.Context, f func(*InstancesListResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeInstancesListEntraIdCertificatesCall¶added inv0.257.0
type InstancesListEntraIdCertificatesCall struct {// contains filtered or unexported fields}func (*InstancesListEntraIdCertificatesCall)Context¶added inv0.257.0
func (c *InstancesListEntraIdCertificatesCall) Context(ctxcontext.Context) *InstancesListEntraIdCertificatesCall
Context sets the context to be used in this call's Do method.
func (*InstancesListEntraIdCertificatesCall)Do¶added inv0.257.0
func (c *InstancesListEntraIdCertificatesCall) Do(opts ...googleapi.CallOption) (*InstancesListEntraIdCertificatesResponse,error)
Do executes the "sql.instances.ListEntraIdCertificates" call.Any non-2xx status code is an error. Response headers are in either*InstancesListEntraIdCertificatesResponse.ServerResponse.Header or (if aresponse was returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*InstancesListEntraIdCertificatesCall)Fields¶added inv0.257.0
func (c *InstancesListEntraIdCertificatesCall) Fields(s ...googleapi.Field) *InstancesListEntraIdCertificatesCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesListEntraIdCertificatesCall)Header¶added inv0.257.0
func (c *InstancesListEntraIdCertificatesCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*InstancesListEntraIdCertificatesCall)IfNoneMatch¶added inv0.257.0
func (c *InstancesListEntraIdCertificatesCall) IfNoneMatch(entityTagstring) *InstancesListEntraIdCertificatesCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeInstancesListEntraIdCertificatesResponse¶added inv0.257.0
type InstancesListEntraIdCertificatesResponse struct {// ActiveVersion: The `sha1_fingerprint` of the active certificate from// `certs`.ActiveVersionstring `json:"activeVersion,omitempty"`// Certs: List of Entra ID certificates for the instance.Certs []*SslCert `json:"certs,omitempty"`// Kind: This is always `sql#instancesListEntraIdCertificates`.Kindstring `json:"kind,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "ActiveVersion") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ActiveVersion") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesListEntraIdCertificatesResponse: Instances ListEntraIdCertificatesresponse.
func (InstancesListEntraIdCertificatesResponse)MarshalJSON¶added inv0.257.0
func (sInstancesListEntraIdCertificatesResponse) MarshalJSON() ([]byte,error)
typeInstancesListResponse¶
type InstancesListResponse struct {// Items: List of database instance resources.Items []*DatabaseInstance `json:"items,omitempty"`// Kind: This is always `sql#instancesList`.Kindstring `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.NextPageTokenstring `json:"nextPageToken,omitempty"`// Warnings: List of warnings that occurred while handling the request.Warnings []*ApiWarning `json:"warnings,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesListResponse: Database instances list response.
func (InstancesListResponse)MarshalJSON¶
func (sInstancesListResponse) MarshalJSON() ([]byte,error)
typeInstancesListServerCasCall¶added inv0.52.0
type InstancesListServerCasCall struct {// contains filtered or unexported fields}func (*InstancesListServerCasCall)Context¶added inv0.52.0
func (c *InstancesListServerCasCall) Context(ctxcontext.Context) *InstancesListServerCasCall
Context sets the context to be used in this call's Do method.
func (*InstancesListServerCasCall)Do¶added inv0.52.0
func (c *InstancesListServerCasCall) Do(opts ...googleapi.CallOption) (*InstancesListServerCasResponse,error)
Do executes the "sql.instances.listServerCas" call.Any non-2xx status code is an error. Response headers are in either*InstancesListServerCasResponse.ServerResponse.Header or (if a response wasreturned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*InstancesListServerCasCall)Fields¶added inv0.52.0
func (c *InstancesListServerCasCall) Fields(s ...googleapi.Field) *InstancesListServerCasCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesListServerCasCall)Header¶added inv0.52.0
func (c *InstancesListServerCasCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*InstancesListServerCasCall)IfNoneMatch¶added inv0.52.0
func (c *InstancesListServerCasCall) IfNoneMatch(entityTagstring) *InstancesListServerCasCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeInstancesListServerCasResponse¶added inv0.52.0
type InstancesListServerCasResponse struct {ActiveVersionstring `json:"activeVersion,omitempty"`// Certs: List of server CA certificates for the instance.Certs []*SslCert `json:"certs,omitempty"`// Kind: This is always `sql#instancesListServerCas`.Kindstring `json:"kind,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "ActiveVersion") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ActiveVersion") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesListServerCasResponse: Instances ListServerCas response.
func (InstancesListServerCasResponse)MarshalJSON¶added inv0.52.0
func (sInstancesListServerCasResponse) MarshalJSON() ([]byte,error)
typeInstancesListServerCertificatesCall¶added inv0.197.0
type InstancesListServerCertificatesCall struct {// contains filtered or unexported fields}func (*InstancesListServerCertificatesCall)Context¶added inv0.197.0
func (c *InstancesListServerCertificatesCall) Context(ctxcontext.Context) *InstancesListServerCertificatesCall
Context sets the context to be used in this call's Do method.
func (*InstancesListServerCertificatesCall)Do¶added inv0.197.0
func (c *InstancesListServerCertificatesCall) Do(opts ...googleapi.CallOption) (*InstancesListServerCertificatesResponse,error)
Do executes the "sql.instances.ListServerCertificates" call.Any non-2xx status code is an error. Response headers are in either*InstancesListServerCertificatesResponse.ServerResponse.Header or (if aresponse was returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*InstancesListServerCertificatesCall)Fields¶added inv0.197.0
func (c *InstancesListServerCertificatesCall) Fields(s ...googleapi.Field) *InstancesListServerCertificatesCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesListServerCertificatesCall)Header¶added inv0.197.0
func (c *InstancesListServerCertificatesCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*InstancesListServerCertificatesCall)IfNoneMatch¶added inv0.197.0
func (c *InstancesListServerCertificatesCall) IfNoneMatch(entityTagstring) *InstancesListServerCertificatesCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeInstancesListServerCertificatesResponse¶added inv0.197.0
type InstancesListServerCertificatesResponse struct {// ActiveVersion: The `sha1_fingerprint` of the active certificate from// `server_certs`.ActiveVersionstring `json:"activeVersion,omitempty"`// CaCerts: List of server CA certificates for the instance.CaCerts []*SslCert `json:"caCerts,omitempty"`// Kind: This is always `sql#instancesListServerCertificates`.Kindstring `json:"kind,omitempty"`// ServerCerts: List of server certificates for the instance, signed by the// corresponding CA from the `ca_certs` list.ServerCerts []*SslCert `json:"serverCerts,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "ActiveVersion") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ActiveVersion") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesListServerCertificatesResponse: Instances ListServerCertificatesresponse.
func (InstancesListServerCertificatesResponse)MarshalJSON¶added inv0.197.0
func (sInstancesListServerCertificatesResponse) MarshalJSON() ([]byte,error)
typeInstancesPatchCall¶added inv0.52.0
type InstancesPatchCall struct {// contains filtered or unexported fields}func (*InstancesPatchCall)Context¶added inv0.52.0
func (c *InstancesPatchCall) Context(ctxcontext.Context) *InstancesPatchCall
Context sets the context to be used in this call's Do method.
func (*InstancesPatchCall)Do¶added inv0.52.0
func (c *InstancesPatchCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.patch" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesPatchCall)Fields¶added inv0.52.0
func (c *InstancesPatchCall) Fields(s ...googleapi.Field) *InstancesPatchCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesPatchCall)Header¶added inv0.52.0
func (c *InstancesPatchCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesPointInTimeRestoreCall¶added inv0.232.0
type InstancesPointInTimeRestoreCall struct {// contains filtered or unexported fields}func (*InstancesPointInTimeRestoreCall)Context¶added inv0.232.0
func (c *InstancesPointInTimeRestoreCall) Context(ctxcontext.Context) *InstancesPointInTimeRestoreCall
Context sets the context to be used in this call's Do method.
func (*InstancesPointInTimeRestoreCall)Do¶added inv0.232.0
func (c *InstancesPointInTimeRestoreCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.pointInTimeRestore" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesPointInTimeRestoreCall)Fields¶added inv0.232.0
func (c *InstancesPointInTimeRestoreCall) Fields(s ...googleapi.Field) *InstancesPointInTimeRestoreCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesPointInTimeRestoreCall)Header¶added inv0.232.0
func (c *InstancesPointInTimeRestoreCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesPreCheckMajorVersionUpgradeCall¶added inv0.250.0
type InstancesPreCheckMajorVersionUpgradeCall struct {// contains filtered or unexported fields}func (*InstancesPreCheckMajorVersionUpgradeCall)Context¶added inv0.250.0
func (c *InstancesPreCheckMajorVersionUpgradeCall) Context(ctxcontext.Context) *InstancesPreCheckMajorVersionUpgradeCall
Context sets the context to be used in this call's Do method.
func (*InstancesPreCheckMajorVersionUpgradeCall)Do¶added inv0.250.0
func (c *InstancesPreCheckMajorVersionUpgradeCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.preCheckMajorVersionUpgrade" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesPreCheckMajorVersionUpgradeCall)Fields¶added inv0.250.0
func (c *InstancesPreCheckMajorVersionUpgradeCall) Fields(s ...googleapi.Field) *InstancesPreCheckMajorVersionUpgradeCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesPreCheckMajorVersionUpgradeCall)Header¶added inv0.250.0
func (c *InstancesPreCheckMajorVersionUpgradeCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesPreCheckMajorVersionUpgradeRequest¶added inv0.250.0
type InstancesPreCheckMajorVersionUpgradeRequest struct {// PreCheckMajorVersionUpgradeContext: Required. Contains details about the// pre-check major version upgrade operation.PreCheckMajorVersionUpgradeContext *PreCheckMajorVersionUpgradeContext `json:"preCheckMajorVersionUpgradeContext,omitempty"`// ForceSendFields is a list of field names (e.g.// "PreCheckMajorVersionUpgradeContext") to unconditionally include in API// requests. By default, fields with empty or default values are omitted from// API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g.// "PreCheckMajorVersionUpgradeContext") to include in API requests with the// JSON null value. By default, fields with empty values are omitted from API// requests. Seehttps://pkg.go.dev/google.golang.org/api#hdr-NullFields for// more details.NullFields []string `json:"-"`}InstancesPreCheckMajorVersionUpgradeRequest: Request for Pre-checks for MVU
func (InstancesPreCheckMajorVersionUpgradeRequest)MarshalJSON¶added inv0.250.0
func (sInstancesPreCheckMajorVersionUpgradeRequest) MarshalJSON() ([]byte,error)
typeInstancesPromoteReplicaCall¶added inv0.52.0
type InstancesPromoteReplicaCall struct {// contains filtered or unexported fields}func (*InstancesPromoteReplicaCall)Context¶added inv0.52.0
func (c *InstancesPromoteReplicaCall) Context(ctxcontext.Context) *InstancesPromoteReplicaCall
Context sets the context to be used in this call's Do method.
func (*InstancesPromoteReplicaCall)Do¶added inv0.52.0
func (c *InstancesPromoteReplicaCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.promoteReplica" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesPromoteReplicaCall)Failover¶added inv0.148.0
func (c *InstancesPromoteReplicaCall) Failover(failoverbool) *InstancesPromoteReplicaCall
Failover sets the optional parameter "failover": Set to true to invoke areplica failover to the DR replica. As part of replica failover, the promoteoperation attempts to add the original primary instance as a replica of thepromoted DR replica when the original primary instance comes back online. Ifset to false or not specified, then the original primary instance becomes anindependent Cloud SQL primary instance.
func (*InstancesPromoteReplicaCall)Fields¶added inv0.52.0
func (c *InstancesPromoteReplicaCall) Fields(s ...googleapi.Field) *InstancesPromoteReplicaCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesPromoteReplicaCall)Header¶added inv0.52.0
func (c *InstancesPromoteReplicaCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesReencryptCall¶added inv0.128.0
type InstancesReencryptCall struct {// contains filtered or unexported fields}func (*InstancesReencryptCall)Context¶added inv0.128.0
func (c *InstancesReencryptCall) Context(ctxcontext.Context) *InstancesReencryptCall
Context sets the context to be used in this call's Do method.
func (*InstancesReencryptCall)Do¶added inv0.128.0
func (c *InstancesReencryptCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.reencrypt" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesReencryptCall)Fields¶added inv0.128.0
func (c *InstancesReencryptCall) Fields(s ...googleapi.Field) *InstancesReencryptCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesReencryptCall)Header¶added inv0.128.0
func (c *InstancesReencryptCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesReencryptRequest¶added inv0.128.0
type InstancesReencryptRequest struct {// BackupReencryptionConfig: Configuration specific to backup re-encryptionBackupReencryptionConfig *BackupReencryptionConfig `json:"backupReencryptionConfig,omitempty"`// ForceSendFields is a list of field names (e.g. "BackupReencryptionConfig")// to unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackupReencryptionConfig") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesReencryptRequest: Database Instance reencrypt request.
func (InstancesReencryptRequest)MarshalJSON¶added inv0.128.0
func (sInstancesReencryptRequest) MarshalJSON() ([]byte,error)
typeInstancesReleaseSsrsLeaseCall¶added inv0.170.0
type InstancesReleaseSsrsLeaseCall struct {// contains filtered or unexported fields}func (*InstancesReleaseSsrsLeaseCall)Context¶added inv0.170.0
func (c *InstancesReleaseSsrsLeaseCall) Context(ctxcontext.Context) *InstancesReleaseSsrsLeaseCall
Context sets the context to be used in this call's Do method.
func (*InstancesReleaseSsrsLeaseCall)Do¶added inv0.170.0
func (c *InstancesReleaseSsrsLeaseCall) Do(opts ...googleapi.CallOption) (*SqlInstancesReleaseSsrsLeaseResponse,error)
Do executes the "sql.instances.releaseSsrsLease" call.Any non-2xx status code is an error. Response headers are in either*SqlInstancesReleaseSsrsLeaseResponse.ServerResponse.Header or (if aresponse was returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*InstancesReleaseSsrsLeaseCall)Fields¶added inv0.170.0
func (c *InstancesReleaseSsrsLeaseCall) Fields(s ...googleapi.Field) *InstancesReleaseSsrsLeaseCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesReleaseSsrsLeaseCall)Header¶added inv0.170.0
func (c *InstancesReleaseSsrsLeaseCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesResetSslConfigCall¶added inv0.52.0
type InstancesResetSslConfigCall struct {// contains filtered or unexported fields}func (*InstancesResetSslConfigCall)Context¶added inv0.52.0
func (c *InstancesResetSslConfigCall) Context(ctxcontext.Context) *InstancesResetSslConfigCall
Context sets the context to be used in this call's Do method.
func (*InstancesResetSslConfigCall)Do¶added inv0.52.0
func (c *InstancesResetSslConfigCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.resetSslConfig" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesResetSslConfigCall)Fields¶added inv0.52.0
func (c *InstancesResetSslConfigCall) Fields(s ...googleapi.Field) *InstancesResetSslConfigCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesResetSslConfigCall)Header¶added inv0.52.0
func (c *InstancesResetSslConfigCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*InstancesResetSslConfigCall)Mode¶added inv0.250.0
func (c *InstancesResetSslConfigCall) Mode(modestring) *InstancesResetSslConfigCall
Mode sets the optional parameter "mode": Reset SSL mode to use.
Possible values:
"RESET_SSL_MODE_UNSPECIFIED" - Reset SSL mode is not specified."ALL" - Refresh all TLS configs. This is the default behaviour."SYNC_FROM_PRIMARY" - Refreshes the replication-related TLS configuration
settings provided by the primary instance. Not applicable to on-premisesreplication instances.
typeInstancesRestartCall¶added inv0.52.0
type InstancesRestartCall struct {// contains filtered or unexported fields}func (*InstancesRestartCall)Context¶added inv0.52.0
func (c *InstancesRestartCall) Context(ctxcontext.Context) *InstancesRestartCall
Context sets the context to be used in this call's Do method.
func (*InstancesRestartCall)Do¶added inv0.52.0
func (c *InstancesRestartCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.restart" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesRestartCall)Fields¶added inv0.52.0
func (c *InstancesRestartCall) Fields(s ...googleapi.Field) *InstancesRestartCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesRestartCall)Header¶added inv0.52.0
func (c *InstancesRestartCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesRestoreBackupCall¶added inv0.52.0
type InstancesRestoreBackupCall struct {// contains filtered or unexported fields}func (*InstancesRestoreBackupCall)Context¶added inv0.52.0
func (c *InstancesRestoreBackupCall) Context(ctxcontext.Context) *InstancesRestoreBackupCall
Context sets the context to be used in this call's Do method.
func (*InstancesRestoreBackupCall)Do¶added inv0.52.0
func (c *InstancesRestoreBackupCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.restoreBackup" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesRestoreBackupCall)Fields¶added inv0.52.0
func (c *InstancesRestoreBackupCall) Fields(s ...googleapi.Field) *InstancesRestoreBackupCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesRestoreBackupCall)Header¶added inv0.52.0
func (c *InstancesRestoreBackupCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesRestoreBackupRequest¶added inv0.52.0
type InstancesRestoreBackupRequest struct {// Backup: The name of the backup that's used to restore a Cloud SQL instance:// Format: projects/{project-id}/backups/{backup-uid}. Only one of// restore_backup_context, backup, backupdr_backup can be passed to the input.Backupstring `json:"backup,omitempty"`// BackupdrBackup: The name of the backup that's used to restore a Cloud SQL// instance: Format:// "projects/{project-id}/locations/{location}/backupVaults/{backupvault}/dataSo// urces/{datasource}/backups/{backup-uid}". Only one of// restore_backup_context, backup, backupdr_backup can be passed to the input.BackupdrBackupstring `json:"backupdrBackup,omitempty"`// RestoreBackupContext: Parameters required to perform the restore backup// operation.RestoreBackupContext *RestoreBackupContext `json:"restoreBackupContext,omitempty"`// RestoreInstanceClearOverridesFieldNames: Optional. This field has the same// purpose as restore_instance_settings, changes any instance settings stored// in the backup you are restoring from. With the difference that these fields// are cleared in the settings.RestoreInstanceClearOverridesFieldNames []string `json:"restoreInstanceClearOverridesFieldNames,omitempty"`// RestoreInstanceSettings: Optional. By using this parameter, Cloud SQL// overrides any instance settings stored in the backup you are restoring from.// You can't change the instance's major database version and you can only// increase the disk size. You can use this field to restore new instances// only. This field is not applicable for restore to existing instances.RestoreInstanceSettings *DatabaseInstance `json:"restoreInstanceSettings,omitempty"`// ForceSendFields is a list of field names (e.g. "Backup") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Backup") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesRestoreBackupRequest: Database instance restore backup request.
func (InstancesRestoreBackupRequest)MarshalJSON¶added inv0.52.0
func (sInstancesRestoreBackupRequest) MarshalJSON() ([]byte,error)
typeInstancesRotateEntraIdCertificateCall¶added inv0.257.0
type InstancesRotateEntraIdCertificateCall struct {// contains filtered or unexported fields}func (*InstancesRotateEntraIdCertificateCall)Context¶added inv0.257.0
func (c *InstancesRotateEntraIdCertificateCall) Context(ctxcontext.Context) *InstancesRotateEntraIdCertificateCall
Context sets the context to be used in this call's Do method.
func (*InstancesRotateEntraIdCertificateCall)Do¶added inv0.257.0
func (c *InstancesRotateEntraIdCertificateCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.RotateEntraIdCertificate" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesRotateEntraIdCertificateCall)Fields¶added inv0.257.0
func (c *InstancesRotateEntraIdCertificateCall) Fields(s ...googleapi.Field) *InstancesRotateEntraIdCertificateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesRotateEntraIdCertificateCall)Header¶added inv0.257.0
func (c *InstancesRotateEntraIdCertificateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesRotateEntraIdCertificateRequest¶added inv0.257.0
type InstancesRotateEntraIdCertificateRequest struct {// RotateEntraIdCertificateContext: Optional. Contains details about the rotate// server certificate operation.RotateEntraIdCertificateContext *RotateEntraIdCertificateContext `json:"rotateEntraIdCertificateContext,omitempty"`// ForceSendFields is a list of field names (e.g.// "RotateEntraIdCertificateContext") to unconditionally include in API// requests. By default, fields with empty or default values are omitted from// API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "RotateEntraIdCertificateContext")// to include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesRotateEntraIdCertificateRequest: Rotate Entra ID certificaterequest.
func (InstancesRotateEntraIdCertificateRequest)MarshalJSON¶added inv0.257.0
func (sInstancesRotateEntraIdCertificateRequest) MarshalJSON() ([]byte,error)
typeInstancesRotateServerCaCall¶added inv0.52.0
type InstancesRotateServerCaCall struct {// contains filtered or unexported fields}func (*InstancesRotateServerCaCall)Context¶added inv0.52.0
func (c *InstancesRotateServerCaCall) Context(ctxcontext.Context) *InstancesRotateServerCaCall
Context sets the context to be used in this call's Do method.
func (*InstancesRotateServerCaCall)Do¶added inv0.52.0
func (c *InstancesRotateServerCaCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.rotateServerCa" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesRotateServerCaCall)Fields¶added inv0.52.0
func (c *InstancesRotateServerCaCall) Fields(s ...googleapi.Field) *InstancesRotateServerCaCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesRotateServerCaCall)Header¶added inv0.52.0
func (c *InstancesRotateServerCaCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesRotateServerCaRequest¶added inv0.52.0
type InstancesRotateServerCaRequest struct {// RotateServerCaContext: Contains details about the rotate server CA// operation.RotateServerCaContext *RotateServerCaContext `json:"rotateServerCaContext,omitempty"`// ForceSendFields is a list of field names (e.g. "RotateServerCaContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "RotateServerCaContext") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesRotateServerCaRequest: Rotate server CA request.
func (InstancesRotateServerCaRequest)MarshalJSON¶added inv0.52.0
func (sInstancesRotateServerCaRequest) MarshalJSON() ([]byte,error)
typeInstancesRotateServerCertificateCall¶added inv0.197.0
type InstancesRotateServerCertificateCall struct {// contains filtered or unexported fields}func (*InstancesRotateServerCertificateCall)Context¶added inv0.197.0
func (c *InstancesRotateServerCertificateCall) Context(ctxcontext.Context) *InstancesRotateServerCertificateCall
Context sets the context to be used in this call's Do method.
func (*InstancesRotateServerCertificateCall)Do¶added inv0.197.0
func (c *InstancesRotateServerCertificateCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.RotateServerCertificate" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesRotateServerCertificateCall)Fields¶added inv0.197.0
func (c *InstancesRotateServerCertificateCall) Fields(s ...googleapi.Field) *InstancesRotateServerCertificateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesRotateServerCertificateCall)Header¶added inv0.197.0
func (c *InstancesRotateServerCertificateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesRotateServerCertificateRequest¶added inv0.197.0
type InstancesRotateServerCertificateRequest struct {// RotateServerCertificateContext: Optional. Contains details about the rotate// server certificate operation.RotateServerCertificateContext *RotateServerCertificateContext `json:"rotateServerCertificateContext,omitempty"`// ForceSendFields is a list of field names (e.g.// "RotateServerCertificateContext") to unconditionally include in API// requests. By default, fields with empty or default values are omitted from// API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "RotateServerCertificateContext")// to include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesRotateServerCertificateRequest: Rotate server certificate request.
func (InstancesRotateServerCertificateRequest)MarshalJSON¶added inv0.197.0
func (sInstancesRotateServerCertificateRequest) MarshalJSON() ([]byte,error)
typeInstancesService¶
type InstancesService struct {// contains filtered or unexported fields}funcNewInstancesService¶
func NewInstancesService(s *Service) *InstancesService
func (*InstancesService)AcquireSsrsLease¶added inv0.170.0
func (r *InstancesService) AcquireSsrsLease(projectstring, instancestring, instancesacquiressrsleaserequest *InstancesAcquireSsrsLeaseRequest) *InstancesAcquireSsrsLeaseCall
AcquireSsrsLease: Acquire a lease for the setup of SQL Server ReportingServices (SSRS).
- instance: Cloud SQL instance ID. This doesn't include the project ID. It'scomposed of lowercase letters, numbers, and hyphens, and it must startwith a letter. The total length must be 98 characters or less (Example:instance-id).
- project: Project ID of the project that contains the instance (Example:project-id).
func (*InstancesService)AddServerCa¶added inv0.52.0
func (r *InstancesService) AddServerCa(projectstring, instancestring) *InstancesAddServerCaCall
AddServerCa: Adds a new trusted Certificate Authority (CA) version for thespecified instance. Required to prepare for a certificate rotation. If a CAversion was previously added but never used in a certificate rotation, thisoperation replaces that version. There cannot be more than one CA versionwaiting to be rotated in. For instances that have enabled CertificateAuthority Service (CAS) based server CA, use AddServerCertificate to add anew server certificate.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)AddServerCertificate¶added inv0.197.0
func (r *InstancesService) AddServerCertificate(projectstring, instancestring) *InstancesAddServerCertificateCall
AddServerCertificate: Add a new trusted server certificate version for thespecified instance using Certificate Authority Service (CAS) server CA.Required to prepare for a certificate rotation. If a server certificateversion was previously added but never used in a certificate rotation, thisoperation replaces that version. There cannot be more than one certificateversion waiting to be rotated in. For instances not using CAS server CA, useAddServerCa instead.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)Clone¶added inv0.52.0
func (r *InstancesService) Clone(projectstring, instancestring, instancesclonerequest *InstancesCloneRequest) *InstancesCloneCall
Clone: Creates a Cloud SQL instance as a clone of the source instance. Usingthis operation might cause your instance to restart.
- instance: The ID of the Cloud SQL instance to be cloned (source). Thisdoes not include the project ID.
- project: Project ID of the source as well as the clone Cloud SQL instance.
func (*InstancesService)Delete¶added inv0.52.0
func (r *InstancesService) Delete(projectstring, instancestring) *InstancesDeleteCall
Delete: Deletes a Cloud SQL instance.
- instance: Cloud SQL instance ID. This does not include the project ID.
- project: Project ID of the project that contains the instance to bedeleted.
func (*InstancesService)Demote¶added inv0.151.0
func (r *InstancesService) Demote(projectstring, instancestring, instancesdemoterequest *InstancesDemoteRequest) *InstancesDemoteCall
Demote: Demotes an existing standalone instance to be a Cloud SQL readreplica for an external database server.
- instance: Cloud SQL instance name.- project: ID of the project that contains the instance.
func (*InstancesService)DemoteMaster¶added inv0.52.0
func (r *InstancesService) DemoteMaster(projectstring, instancestring, instancesdemotemasterrequest *InstancesDemoteMasterRequest) *InstancesDemoteMasterCall
DemoteMaster: Demotes the stand-alone instance to be a Cloud SQL readreplica for an external database server.
- instance: Cloud SQL instance name.- project: ID of the project that contains the instance.
func (*InstancesService)ExecuteSql¶added inv0.248.0
func (r *InstancesService) ExecuteSql(projectstring, instancestring, executesqlpayload *ExecuteSqlPayload) *InstancesExecuteSqlCall
ExecuteSql: Execute SQL statements.
- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)Export¶added inv0.52.0
func (r *InstancesService) Export(projectstring, instancestring, instancesexportrequest *InstancesExportRequest) *InstancesExportCall
Export: Exports data from a Cloud SQL instance to a Cloud Storage bucket asa SQL dump or CSV file.
- instance: Cloud SQL instance ID. This does not include the project ID.
- project: Project ID of the project that contains the instance to beexported.
func (*InstancesService)Failover¶added inv0.52.0
func (r *InstancesService) Failover(projectstring, instancestring, instancesfailoverrequest *InstancesFailoverRequest) *InstancesFailoverCall
Failover: Initiates a manual failover of a high availability (HA) primaryinstance to a standby instance, which becomes the primary instance. Usersare then rerouted to the new primary. For more information, see the Overviewof high availability(https://cloud.google.com/sql/docs/mysql/high-availability) page in theCloud SQL documentation. If using Legacy HA (MySQL only), this causes theinstance to failover to its failover replica instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: ID of the project that contains the read replica.
func (*InstancesService)Get¶added inv0.52.0
func (r *InstancesService) Get(projectstring, instancestring) *InstancesGetCall
Get: Retrieves a resource containing information about a Cloud SQL instance.
- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)Import¶added inv0.52.0
func (r *InstancesService) Import(projectstring, instancestring, instancesimportrequest *InstancesImportRequest) *InstancesImportCall
Import: Imports data into a Cloud SQL instance from a SQL dump or CSV filein Cloud Storage.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)Insert¶added inv0.52.0
func (r *InstancesService) Insert(projectstring, databaseinstance *DatabaseInstance) *InstancesInsertCall
Insert: Creates a new Cloud SQL instance.
- project: Project ID of the project to which the newly created Cloud SQLinstances should belong.
func (*InstancesService)List¶
func (r *InstancesService) List(projectstring) *InstancesListCall
List: Lists instances under a given project.
- project: Project ID of the project for which to list Cloud SQL instances.
func (*InstancesService)ListEntraIdCertificates¶added inv0.257.0
func (r *InstancesService) ListEntraIdCertificates(projectstring, instancestring) *InstancesListEntraIdCertificatesCall
ListEntraIdCertificates: Lists all versions of EntraID certificates for thespecified instance. There can be up to three sets of certificates listed:the certificate that is currently in use, a future that has been added butnot yet used to sign a certificate, and a certificate that has been rotatedout.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)ListServerCas¶added inv0.52.0
func (r *InstancesService) ListServerCas(projectstring, instancestring) *InstancesListServerCasCall
ListServerCas: Lists all of the trusted Certificate Authorities (CAs) forthe specified instance. There can be up to three CAs listed: the CA that wasused to sign the certificate that is currently in use, a CA that has beenadded but not yet used to sign a certificate, and a CA used to sign acertificate that has previously rotated out.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)ListServerCertificates¶added inv0.197.0
func (r *InstancesService) ListServerCertificates(projectstring, instancestring) *InstancesListServerCertificatesCall
ListServerCertificates: Lists all versions of server certificates andcertificate authorities (CAs) for the specified instance. There can be up tothree sets of certs listed: the certificate that is currently in use, afuture that has been added but not yet used to sign a certificate, and acertificate that has been rotated out. For instances not using CertificateAuthority Service (CAS) server CA, use ListServerCas instead.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)Patch¶added inv0.52.0
func (r *InstancesService) Patch(projectstring, instancestring, databaseinstance *DatabaseInstance) *InstancesPatchCall
Patch: Partially updates settings of a Cloud SQL instance by merging therequest with the current configuration. This method supports patchsemantics.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)PointInTimeRestore¶added inv0.232.0
func (r *InstancesService) PointInTimeRestore(parentstring, pointintimerestorecontext *PointInTimeRestoreContext) *InstancesPointInTimeRestoreCall
PointInTimeRestore: Point in time restore for an instance managed by GoogleCloud Backup and Disaster Recovery.
- parent: The parent resource where you created this instance. Format:projects/{project}.
func (*InstancesService)PreCheckMajorVersionUpgrade¶added inv0.250.0
func (r *InstancesService) PreCheckMajorVersionUpgrade(projectstring, instancestring, instancesprecheckmajorversionupgraderequest *InstancesPreCheckMajorVersionUpgradeRequest) *InstancesPreCheckMajorVersionUpgradeCall
PreCheckMajorVersionUpgrade: Execute MVU Pre-checks
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)PromoteReplica¶added inv0.52.0
func (r *InstancesService) PromoteReplica(projectstring, instancestring) *InstancesPromoteReplicaCall
PromoteReplica: Promotes the read replica instance to be an independentCloud SQL primary instance. Using this operation might cause your instanceto restart.
- instance: Cloud SQL read replica instance name.- project: ID of the project that contains the read replica.
func (*InstancesService)Reencrypt¶added inv0.128.0
func (r *InstancesService) Reencrypt(projectstring, instancestring, instancesreencryptrequest *InstancesReencryptRequest) *InstancesReencryptCall
Reencrypt: Reencrypt CMEK instance with latest key version.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: ID of the project that contains the instance.
func (*InstancesService)ReleaseSsrsLease¶added inv0.170.0
func (r *InstancesService) ReleaseSsrsLease(projectstring, instancestring) *InstancesReleaseSsrsLeaseCall
ReleaseSsrsLease: Release a lease for the setup of SQL Server ReportingServices (SSRS).
- instance: The Cloud SQL instance ID. This doesn't include the project ID.The instance ID contains lowercase letters, numbers, and hyphens, and itmust start with a letter. This ID can have a maximum length of 98characters.
- project: The project ID that contains the instance.
func (*InstancesService)ResetSslConfig¶added inv0.52.0
func (r *InstancesService) ResetSslConfig(projectstring, instancestring) *InstancesResetSslConfigCall
ResetSslConfig: Deletes all client certificates and generates a new serverSSL certificate for the instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)Restart¶added inv0.52.0
func (r *InstancesService) Restart(projectstring, instancestring) *InstancesRestartCall
Restart: Restarts a Cloud SQL instance.
- instance: Cloud SQL instance ID. This does not include the project ID.
- project: Project ID of the project that contains the instance to berestarted.
func (*InstancesService)RestoreBackup¶added inv0.52.0
func (r *InstancesService) RestoreBackup(projectstring, instancestring, instancesrestorebackuprequest *InstancesRestoreBackupRequest) *InstancesRestoreBackupCall
RestoreBackup: Restores a backup of a Cloud SQL instance. Using thisoperation might cause your instance to restart.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)RotateEntraIdCertificate¶added inv0.257.0
func (r *InstancesService) RotateEntraIdCertificate(projectstring, instancestring, instancesrotateentraidcertificaterequest *InstancesRotateEntraIdCertificateRequest) *InstancesRotateEntraIdCertificateCall
RotateEntraIdCertificate: Rotates the server certificate version to onepreviously added with the addEntraIdCertificate method.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)RotateServerCa¶added inv0.52.0
func (r *InstancesService) RotateServerCa(projectstring, instancestring, instancesrotateservercarequest *InstancesRotateServerCaRequest) *InstancesRotateServerCaCall
RotateServerCa: Rotates the server certificate to one signed by theCertificate Authority (CA) version previously added with the addServerCAmethod. For instances that have enabled Certificate Authority Service (CAS)based server CA, use RotateServerCertificate to rotate the servercertificate.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)RotateServerCertificate¶added inv0.197.0
func (r *InstancesService) RotateServerCertificate(projectstring, instancestring, instancesrotateservercertificaterequest *InstancesRotateServerCertificateRequest) *InstancesRotateServerCertificateCall
RotateServerCertificate: Rotates the server certificate version to onepreviously added with the addServerCertificate method. For instances notusing Certificate Authority Service (CAS) server CA, use RotateServerCainstead.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*InstancesService)StartReplica¶added inv0.52.0
func (r *InstancesService) StartReplica(projectstring, instancestring) *InstancesStartReplicaCall
StartReplica: Starts the replication in the read replica instance.
- instance: Cloud SQL read replica instance name.- project: ID of the project that contains the read replica.
func (*InstancesService)StopReplica¶added inv0.52.0
func (r *InstancesService) StopReplica(projectstring, instancestring) *InstancesStopReplicaCall
StopReplica: Stops the replication in the read replica instance.
- instance: Cloud SQL read replica instance name.- project: ID of the project that contains the read replica.
func (*InstancesService)Switchover¶added inv0.148.0
func (r *InstancesService) Switchover(projectstring, instancestring) *InstancesSwitchoverCall
Switchover: Switches over from the primary instance to the DR replicainstance.
- instance: Cloud SQL read replica instance name.- project: ID of the project that contains the replica.
func (*InstancesService)TruncateLog¶added inv0.52.0
func (r *InstancesService) TruncateLog(projectstring, instancestring, instancestruncatelogrequest *InstancesTruncateLogRequest) *InstancesTruncateLogCall
TruncateLog: Truncate MySQL general and slow query log tables MySQL only.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the Cloud SQL project.
func (*InstancesService)Update¶added inv0.52.0
func (r *InstancesService) Update(projectstring, instancestring, databaseinstance *DatabaseInstance) *InstancesUpdateCall
Update: Updates settings of a Cloud SQL instance. Using this operation mightcause your instance to restart.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
typeInstancesStartReplicaCall¶added inv0.52.0
type InstancesStartReplicaCall struct {// contains filtered or unexported fields}func (*InstancesStartReplicaCall)Context¶added inv0.52.0
func (c *InstancesStartReplicaCall) Context(ctxcontext.Context) *InstancesStartReplicaCall
Context sets the context to be used in this call's Do method.
func (*InstancesStartReplicaCall)Do¶added inv0.52.0
func (c *InstancesStartReplicaCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.startReplica" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesStartReplicaCall)Fields¶added inv0.52.0
func (c *InstancesStartReplicaCall) Fields(s ...googleapi.Field) *InstancesStartReplicaCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesStartReplicaCall)Header¶added inv0.52.0
func (c *InstancesStartReplicaCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesStopReplicaCall¶added inv0.52.0
type InstancesStopReplicaCall struct {// contains filtered or unexported fields}func (*InstancesStopReplicaCall)Context¶added inv0.52.0
func (c *InstancesStopReplicaCall) Context(ctxcontext.Context) *InstancesStopReplicaCall
Context sets the context to be used in this call's Do method.
func (*InstancesStopReplicaCall)Do¶added inv0.52.0
func (c *InstancesStopReplicaCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.stopReplica" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesStopReplicaCall)Fields¶added inv0.52.0
func (c *InstancesStopReplicaCall) Fields(s ...googleapi.Field) *InstancesStopReplicaCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesStopReplicaCall)Header¶added inv0.52.0
func (c *InstancesStopReplicaCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesSwitchoverCall¶added inv0.148.0
type InstancesSwitchoverCall struct {// contains filtered or unexported fields}func (*InstancesSwitchoverCall)Context¶added inv0.148.0
func (c *InstancesSwitchoverCall) Context(ctxcontext.Context) *InstancesSwitchoverCall
Context sets the context to be used in this call's Do method.
func (*InstancesSwitchoverCall)DbTimeout¶added inv0.148.0
func (c *InstancesSwitchoverCall) DbTimeout(dbTimeoutstring) *InstancesSwitchoverCall
DbTimeout sets the optional parameter "dbTimeout": (MySQL and PostgreSQLonly) Cloud SQL instance operations timeout, which is a sum of all databaseoperations. Default value is 10 minutes and can be modified to a maximumvalue of 24 hours.
func (*InstancesSwitchoverCall)Do¶added inv0.148.0
func (c *InstancesSwitchoverCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.switchover" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesSwitchoverCall)Fields¶added inv0.148.0
func (c *InstancesSwitchoverCall) Fields(s ...googleapi.Field) *InstancesSwitchoverCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesSwitchoverCall)Header¶added inv0.148.0
func (c *InstancesSwitchoverCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesTruncateLogCall¶added inv0.52.0
type InstancesTruncateLogCall struct {// contains filtered or unexported fields}func (*InstancesTruncateLogCall)Context¶added inv0.52.0
func (c *InstancesTruncateLogCall) Context(ctxcontext.Context) *InstancesTruncateLogCall
Context sets the context to be used in this call's Do method.
func (*InstancesTruncateLogCall)Do¶added inv0.52.0
func (c *InstancesTruncateLogCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.truncateLog" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesTruncateLogCall)Fields¶added inv0.52.0
func (c *InstancesTruncateLogCall) Fields(s ...googleapi.Field) *InstancesTruncateLogCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesTruncateLogCall)Header¶added inv0.52.0
func (c *InstancesTruncateLogCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInstancesTruncateLogRequest¶added inv0.52.0
type InstancesTruncateLogRequest struct {// TruncateLogContext: Contains details about the truncate log operation.TruncateLogContext *TruncateLogContext `json:"truncateLogContext,omitempty"`// ForceSendFields is a list of field names (e.g. "TruncateLogContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "TruncateLogContext") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}InstancesTruncateLogRequest: Instance truncate log request.
func (InstancesTruncateLogRequest)MarshalJSON¶added inv0.52.0
func (sInstancesTruncateLogRequest) MarshalJSON() ([]byte,error)
typeInstancesUpdateCall¶added inv0.52.0
type InstancesUpdateCall struct {// contains filtered or unexported fields}func (*InstancesUpdateCall)Context¶added inv0.52.0
func (c *InstancesUpdateCall) Context(ctxcontext.Context) *InstancesUpdateCall
Context sets the context to be used in this call's Do method.
func (*InstancesUpdateCall)Do¶added inv0.52.0
func (c *InstancesUpdateCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.instances.update" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*InstancesUpdateCall)Fields¶added inv0.52.0
func (c *InstancesUpdateCall) Fields(s ...googleapi.Field) *InstancesUpdateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*InstancesUpdateCall)Header¶added inv0.52.0
func (c *InstancesUpdateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeInterval¶added inv0.222.0
type Interval struct {// EndTime: Optional. Exclusive end of the interval. If specified, a Timestamp// matching this interval will have to be before the end.EndTimestring `json:"endTime,omitempty"`// StartTime: Optional. Inclusive start of the interval. If specified, a// Timestamp matching this interval will have to be the same or after the// start.StartTimestring `json:"startTime,omitempty"`// ForceSendFields is a list of field names (e.g. "EndTime") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "EndTime") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Interval: Represents a time interval, encoded as a Timestamp start(inclusive) and a Timestamp end (exclusive). The start must be less than orequal to the end. When the start equals the end, the interval is empty(matches no time). When both start and end are unspecified, the intervalmatches any time.
func (Interval)MarshalJSON¶added inv0.222.0
typeIpConfiguration¶
type IpConfiguration struct {// AllocatedIpRange: The name of the allocated ip range for the private ip// Cloud SQL instance. For example: "google-managed-services-default". If set,// the instance ip will be created in the allocated range. The range name must// comply withRFC 1035 (https://tools.ietf.org/html/rfc1035). Specifically,// the name must be 1-63 characters long and match the regular expression// `[a-z]([-a-z0-9]*[a-z0-9])?.`AllocatedIpRangestring `json:"allocatedIpRange,omitempty"`// 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 (for example: `157.197.200.0/24`).AuthorizedNetworks []*AclEntry `json:"authorizedNetworks,omitempty"`// CustomSubjectAlternativeNames: Optional. Custom Subject Alternative// Name(SAN)s for a Cloud SQL instance.CustomSubjectAlternativeNames []string `json:"customSubjectAlternativeNames,omitempty"`// EnablePrivatePathForGoogleCloudServices: Controls connectivity to private IP// instances from Google services, such as BigQuery.EnablePrivatePathForGoogleCloudServicesbool `json:"enablePrivatePathForGoogleCloudServices,omitempty"`// Ipv4Enabled: Whether the instance is assigned a public IP address or not.Ipv4Enabledbool `json:"ipv4Enabled,omitempty"`// PrivateNetwork: The resource link for the VPC network from which the Cloud// SQL instance is accessible for private IP. For example,// `/projects/myProject/global/networks/default`. This setting can be updated,// but it cannot be removed after it is set.PrivateNetworkstring `json:"privateNetwork,omitempty"`// PscConfig: PSC settings for this instance.PscConfig *PscConfig `json:"pscConfig,omitempty"`// RequireSsl: Use `ssl_mode` instead. Whether SSL/TLS connections over IP are// enforced. If set to false, then allow both non-SSL/non-TLS and SSL/TLS// connections. For SSL/TLS connections, the client certificate won't be// verified. If set to true, then only allow connections encrypted with SSL/TLS// and with valid client certificates. If you want to enforce SSL/TLS without// enforcing the requirement for valid client certificates, then use the// `ssl_mode` flag instead of the `require_ssl` flag.RequireSslbool `json:"requireSsl,omitempty"`// ServerCaMode: Specify what type of CA is used for the server certificate.//// Possible values:// "CA_MODE_UNSPECIFIED" - CA mode is unspecified. It is effectively the same// as `GOOGLE_MANAGED_INTERNAL_CA`.// "GOOGLE_MANAGED_INTERNAL_CA" - Google-managed self-signed internal CA.// "GOOGLE_MANAGED_CAS_CA" - Google-managed regional CA part of root CA// hierarchy hosted on Google Cloud's Certificate Authority Service (CAS).// "CUSTOMER_MANAGED_CAS_CA" - Customer-managed CA hosted on Google Cloud's// Certificate Authority Service (CAS).ServerCaModestring `json:"serverCaMode,omitempty"`// ServerCaPool: Optional. The resource name of the server CA pool for an// instance with `CUSTOMER_MANAGED_CAS_CA` as the `server_ca_mode`. Format:// projects/{PROJECT}/locations/{REGION}/caPools/{CA_POOL_ID}ServerCaPoolstring `json:"serverCaPool,omitempty"`// ServerCertificateRotationMode: Optional. Controls the automatic server// certificate rotation feature. This feature is disabled by default. When// enabled, the server certificate will be automatically rotated during Cloud// SQL scheduled maintenance or self-service maintenance updates up to six// months before it expires. This setting can only be set if server_ca_mode is// either GOOGLE_MANAGED_CAS_CA or CUSTOMER_MANAGED_CAS_CA.//// Possible values:// "SERVER_CERTIFICATE_ROTATION_MODE_UNSPECIFIED" - Unspecified: no automatic// server certificate rotation.// "NO_AUTOMATIC_ROTATION" - No automatic server certificate rotation. The// user must [manage server certificate// rotation](/sql/docs/mysql/manage-ssl-instance#rotate-server-certificate-cas)// on their side.// "AUTOMATIC_ROTATION_DURING_MAINTENANCE" - Automatic server certificate// rotation during Cloud SQL scheduled maintenance or self-service maintenance// updates. Requires `server_ca_mode` to be `GOOGLE_MANAGED_CAS_CA` or// `CUSTOMER_MANAGED_CAS_CA`.ServerCertificateRotationModestring `json:"serverCertificateRotationMode,omitempty"`// SslMode: Specify how SSL/TLS is enforced in database connections. If you// must use the `require_ssl` flag for backward compatibility, then only the// following value pairs are valid: For PostgreSQL and MySQL: *// `ssl_mode=ALLOW_UNENCRYPTED_AND_ENCRYPTED` and `require_ssl=false` *// `ssl_mode=ENCRYPTED_ONLY` and `require_ssl=false` *// `ssl_mode=TRUSTED_CLIENT_CERTIFICATE_REQUIRED` and `require_ssl=true` For// SQL Server: * `ssl_mode=ALLOW_UNENCRYPTED_AND_ENCRYPTED` and// `require_ssl=false` * `ssl_mode=ENCRYPTED_ONLY` and `require_ssl=true` The// value of `ssl_mode` has priority over the value of `require_ssl`. For// example, for the pair `ssl_mode=ENCRYPTED_ONLY` and `require_ssl=false`,// `ssl_mode=ENCRYPTED_ONLY` means accept only SSL connections, while// `require_ssl=false` means accept both non-SSL and SSL connections. In this// case, MySQL and PostgreSQL databases respect `ssl_mode` and accepts only SSL// connections.//// Possible values:// "SSL_MODE_UNSPECIFIED" - The SSL mode is unknown.// "ALLOW_UNENCRYPTED_AND_ENCRYPTED" - Allow non-SSL/non-TLS and SSL/TLS// connections. For SSL connections to MySQL and PostgreSQL, the client// certificate isn't verified. When this value is used, the legacy// `require_ssl` flag must be false or cleared to avoid a conflict between the// values of the two flags.// "ENCRYPTED_ONLY" - Only allow connections encrypted with SSL/TLS. For SSL// connections to MySQL and PostgreSQL, the client certificate isn't verified.// When this value is used, the legacy `require_ssl` flag must be false or// cleared to avoid a conflict between the values of the two flags.// "TRUSTED_CLIENT_CERTIFICATE_REQUIRED" - Only allow connections encrypted// with SSL/TLS and with valid client certificates. When this value is used,// the legacy `require_ssl` flag must be true or cleared to avoid the conflict// between values of two flags. PostgreSQL clients or users that connect using// IAM database authentication must use either the [Cloud SQL Auth// Proxy](https://cloud.google.com/sql/docs/postgres/connect-auth-proxy) or// [Cloud SQL// Connectors](https://cloud.google.com/sql/docs/postgres/connect-connectors)// to enforce client identity verification. Only applicable to MySQL and// PostgreSQL. Not applicable to SQL Server.SslModestring `json:"sslMode,omitempty"`// ForceSendFields is a list of field names (e.g. "AllocatedIpRange") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AllocatedIpRange") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}IpConfiguration: IP Management configuration.
func (IpConfiguration)MarshalJSON¶
func (sIpConfiguration) MarshalJSON() ([]byte,error)
typeIpMapping¶
type IpMapping struct {// IpAddress: The IP address assigned.IpAddressstring `json:"ipAddress,omitempty"`// TimeToRetire: The due time for this IP to be retired inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`. This field is only available when the IP is// scheduled to be retired.TimeToRetirestring `json:"timeToRetire,omitempty"`// Type: The type of this IP address. A `PRIMARY` address is a public address// that can accept incoming connections. A `PRIVATE` address is a private// address that can accept incoming connections. An `OUTGOING` address is the// source address of connections originating from the instance, if supported.//// Possible values:// "SQL_IP_ADDRESS_TYPE_UNSPECIFIED" - This is an unknown IP address type.// "PRIMARY" - IP address the customer is supposed to connect to. Usually// this is the load balancer's IP address// "OUTGOING" - Source IP address of the connection a read replica// establishes to its external primary instance. This IP address can be// allowlisted by the customer in case it has a firewall that filters incoming// connection to its on premises primary instance.// "PRIVATE" - Private IP used when using private IPs and network peering.// "MIGRATED_1ST_GEN" - V1 IP of a migrated instance. We want the user to// decommission this IP as soon as the migration is complete. Note: V1// instances with V1 ip addresses will be counted as PRIMARY.Typestring `json:"type,omitempty"`// ForceSendFields is a list of field names (e.g. "IpAddress") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "IpAddress") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}IpMapping: Database instance IP mapping
func (IpMapping)MarshalJSON¶
typeListBackupsResponse¶added inv0.222.0
type ListBackupsResponse struct {// Backups: A list of backups.Backups []*Backup `json:"backups,omitempty"`// NextPageToken: A token, which can be sent as `page_token` to retrieve the// next page. If this field is omitted, then there aren't subsequent pages.NextPageTokenstring `json:"nextPageToken,omitempty"`// Warnings: If a region isn't unavailable or if an unknown error occurs, then// a warning message is returned.Warnings []*ApiWarning `json:"warnings,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Backups") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Backups") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ListBackupsResponse: The response payload containing a list of the backups.
func (ListBackupsResponse)MarshalJSON¶added inv0.222.0
func (sListBackupsResponse) MarshalJSON() ([]byte,error)
typeLocationPreference¶
type LocationPreference struct {// FollowGaeApplication: The App Engine application to follow, it must be in// the same region as the Cloud SQL instance. WARNING: Changing this might// restart the instance.FollowGaeApplicationstring `json:"followGaeApplication,omitempty"`// Kind: This is always `sql#locationPreference`.Kindstring `json:"kind,omitempty"`// SecondaryZone: The preferred Compute Engine zone for the secondary/failover// (for example: us-central1-a, us-central1-b, etc.). To disable this field,// set it to 'no_secondary_zone'.SecondaryZonestring `json:"secondaryZone,omitempty"`// Zone: The preferred Compute Engine zone (for example: us-central1-a,// us-central1-b, etc.). WARNING: Changing this might restart the instance.Zonestring `json:"zone,omitempty"`// ForceSendFields is a list of field names (e.g. "FollowGaeApplication") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "FollowGaeApplication") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}LocationPreference: Preferred location. This specifies where a Cloud SQLinstance is located. Note that if the preferred location is not available,the instance will be located as close as possible within the region. Onlyone location may be specified.
func (LocationPreference)MarshalJSON¶
func (sLocationPreference) MarshalJSON() ([]byte,error)
typeMaintenanceWindow¶
type MaintenanceWindow struct {// Day: Day of week - `MONDAY`, `TUESDAY`, `WEDNESDAY`, `THURSDAY`, `FRIDAY`,// `SATURDAY`, or `SUNDAY`. Specify in the UTC time zone. Returned in output as// an integer, 1 to 7, where `1` equals Monday.Dayint64 `json:"day,omitempty"`// Hour: Hour of day - 0 to 23. Specify in the UTC time zone.Hourint64 `json:"hour,omitempty"`// Kind: This is always `sql#maintenanceWindow`.Kindstring `json:"kind,omitempty"`// UpdateTrack: Maintenance timing settings: `canary`, `stable`, or `week5`.// For more information, see About maintenance on Cloud SQL instances// (https://cloud.google.com/sql/docs/mysql/maintenance).//// Possible values:// "SQL_UPDATE_TRACK_UNSPECIFIED" - This is an unknown maintenance timing// preference.// "canary" - For an instance with a scheduled maintenance window, this// maintenance timing indicates that the maintenance update is scheduled 7 to// 14 days after the notification is sent out. Also referred to as `Week 1`// (Console) and `preview` (gcloud CLI).// "stable" - For an instance with a scheduled maintenance window, this// maintenance timing indicates that the maintenance update is scheduled 15 to// 21 days after the notification is sent out. Also referred to as `Week 2`// (Console) and `production` (gcloud CLI).// "week5" - For instance with a scheduled maintenance window, this// maintenance timing indicates that the maintenance update is scheduled 35 to// 42 days after the notification is sent out.UpdateTrackstring `json:"updateTrack,omitempty"`// ForceSendFields is a list of field names (e.g. "Day") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Day") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MaintenanceWindow: Maintenance window. This specifies when a Cloud SQLinstance is restarted for system maintenance purposes.
func (MaintenanceWindow)MarshalJSON¶
func (sMaintenanceWindow) MarshalJSON() ([]byte,error)
typeMessage¶added inv0.250.0
type Message struct {// Message: The full message string. For PostgreSQL, this is a formatted string// that may include severity, code, and the notice/warning message. For MySQL,// this contains the warning message.Messagestring `json:"message,omitempty"`// Severity: The severity of the message (e.g., "NOTICE" for PostgreSQL,// "WARNING" for MySQL).Severitystring `json:"severity,omitempty"`// ForceSendFields is a list of field names (e.g. "Message") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Message") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Message: Represents a notice or warning message from the database.
func (Message)MarshalJSON¶added inv0.250.0
typeMetadata¶added inv0.248.0
type Metadata struct {// SqlStatementExecutionTime: The time taken to execute the SQL statements.SqlStatementExecutionTimestring `json:"sqlStatementExecutionTime,omitempty"`// ForceSendFields is a list of field names (e.g. "SqlStatementExecutionTime")// to unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "SqlStatementExecutionTime") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Metadata: The additional metadata information regarding the execution of theSQL statements.
func (Metadata)MarshalJSON¶added inv0.248.0
typeMySqlReplicaConfiguration¶
type MySqlReplicaConfiguration struct {// CaCertificate: PEM representation of the trusted CA's x509 certificate.CaCertificatestring `json:"caCertificate,omitempty"`// ClientCertificate: PEM representation of the replica's x509 certificate.ClientCertificatestring `json:"clientCertificate,omitempty"`// ClientKey: PEM representation of the replica's private key. The// corresponding public key is encoded in the client's certificate.ClientKeystring `json:"clientKey,omitempty"`// ConnectRetryInterval: Seconds to wait between connect retries. MySQL's// default is 60 seconds.ConnectRetryIntervalint64 `json:"connectRetryInterval,omitempty"`// DumpFilePath: Path to a SQL dump file in Google Cloud Storage from which the// replica instance is to be created. The URI is in the form// gs://bucketName/fileName. Compressed gzip files (.gz) are also supported.// Dumps have the binlog co-ordinates from which replication begins. This can// be accomplished by setting --master-data to 1 when using mysqldump.DumpFilePathstring `json:"dumpFilePath,omitempty"`// Kind: This is always `sql#mysqlReplicaConfiguration`.Kindstring `json:"kind,omitempty"`// MasterHeartbeatPeriod: Interval in milliseconds between replication// heartbeats.MasterHeartbeatPeriodint64 `json:"masterHeartbeatPeriod,omitempty,string"`// Password: The password for the replication connection.Passwordstring `json:"password,omitempty"`// SslCipher: A list of permissible ciphers to use for SSL encryption.SslCipherstring `json:"sslCipher,omitempty"`// Username: The username for the replication connection.Usernamestring `json:"username,omitempty"`// VerifyServerCertificate: Whether or not to check the primary instance's// Common Name value in the certificate that it sends during the SSL handshake.VerifyServerCertificatebool `json:"verifyServerCertificate,omitempty"`// ForceSendFields is a list of field names (e.g. "CaCertificate") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CaCertificate") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MySqlReplicaConfiguration: Read-replica configuration specific to MySQLdatabases.
func (MySqlReplicaConfiguration)MarshalJSON¶
func (sMySqlReplicaConfiguration) MarshalJSON() ([]byte,error)
typeMySqlSyncConfig¶added inv0.53.0
type MySqlSyncConfig struct {// InitialSyncFlags: Flags to use for the initial dump.InitialSyncFlags []*SyncFlags `json:"initialSyncFlags,omitempty"`// ForceSendFields is a list of field names (e.g. "InitialSyncFlags") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "InitialSyncFlags") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}MySqlSyncConfig: MySQL-specific external server sync settings.
func (MySqlSyncConfig)MarshalJSON¶added inv0.55.0
func (sMySqlSyncConfig) MarshalJSON() ([]byte,error)
typeOnPremisesConfiguration¶
type OnPremisesConfiguration struct {// CaCertificate: PEM representation of the trusted CA's x509 certificate.CaCertificatestring `json:"caCertificate,omitempty"`// ClientCertificate: PEM representation of the replica's x509 certificate.ClientCertificatestring `json:"clientCertificate,omitempty"`// ClientKey: PEM representation of the replica's private key. The// corresponding public key is encoded in the client's certificate.ClientKeystring `json:"clientKey,omitempty"`// DumpFilePath: The dump file to create the Cloud SQL replica.DumpFilePathstring `json:"dumpFilePath,omitempty"`// HostPort: The host and port of the on-premises instance in host:port formatHostPortstring `json:"hostPort,omitempty"`// Kind: This is always `sql#onPremisesConfiguration`.Kindstring `json:"kind,omitempty"`// Password: The password for connecting to on-premises instance.Passwordstring `json:"password,omitempty"`// SelectedObjects: Optional. A list of objects that the user selects for// replication from an external source instance.SelectedObjects []*SelectedObjects `json:"selectedObjects,omitempty"`// SourceInstance: The reference to Cloud SQL instance if the source is Cloud// SQL.SourceInstance *InstanceReference `json:"sourceInstance,omitempty"`// SslOption: Optional. SSL option for replica connection to the on-premises// source.//// Possible values:// "SSL_OPTION_UNSPECIFIED" - Unknown SSL option i.e. SSL option not// specified by user.// "DISABLE" - SSL is not used for replica connection to the on-premises// source.// "REQUIRE" - SSL is required for replica connection to the on-premises// source.// "VERIFY_CA" - Verify CA is required for replica connection to the// on-premises source.SslOptionstring `json:"sslOption,omitempty"`// Username: The username for connecting to on-premises instance.Usernamestring `json:"username,omitempty"`// ForceSendFields is a list of field names (e.g. "CaCertificate") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CaCertificate") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}OnPremisesConfiguration: On-premises instance configuration.
func (OnPremisesConfiguration)MarshalJSON¶
func (sOnPremisesConfiguration) MarshalJSON() ([]byte,error)
typeOperation¶added inv0.52.0
type Operation struct {// AcquireSsrsLeaseContext: The context for acquire SSRS lease operation, if// applicable.AcquireSsrsLeaseContext *AcquireSsrsLeaseContext `json:"acquireSsrsLeaseContext,omitempty"`// ApiWarning: An Admin API warning message.ApiWarning *ApiWarning `json:"apiWarning,omitempty"`// BackupContext: The context for backup operation, if applicable.BackupContext *BackupContext `json:"backupContext,omitempty"`// EndTime: The time this operation finished in UTC timezone inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.EndTimestring `json:"endTime,omitempty"`// Error: If errors occurred during processing of this operation, this field// will be populated.Error *OperationErrors `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"`// InsertTime: The time this operation was enqueued in UTC timezone inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.InsertTimestring `json:"insertTime,omitempty"`// Kind: This is always `sql#operation`.Kindstring `json:"kind,omitempty"`// Name: An identifier that uniquely identifies the operation. You can use this// identifier to retrieve the Operations resource that has information about// the operation.Namestring `json:"name,omitempty"`// OperationType: The type of the operation. Valid values are: * `CREATE` *// `DELETE` * `UPDATE` * `RESTART` * `IMPORT` * `EXPORT` * `BACKUP_VOLUME` *// `RESTORE_VOLUME` * `CREATE_USER` * `DELETE_USER` * `CREATE_DATABASE` *// `DELETE_DATABASE`//// Possible values:// "SQL_OPERATION_TYPE_UNSPECIFIED" - Unknown operation type.// "IMPORT" - Imports data into a Cloud SQL instance.// "EXPORT" - Exports data from a Cloud SQL instance to a Cloud Storage// bucket.// "CREATE" - Creates a new Cloud SQL instance.// "UPDATE" - Updates the settings of a Cloud SQL instance.// "DELETE" - Deletes a Cloud SQL instance.// "RESTART" - Restarts the Cloud SQL instance.// "BACKUP"// "SNAPSHOT"// "BACKUP_VOLUME" - Performs instance backup.// "DELETE_VOLUME" - Deletes an instance backup.// "RESTORE_VOLUME" - Restores an instance backup.// "INJECT_USER" - Injects a privileged user in mysql for MOB instances.// "CLONE" - Clones a Cloud SQL instance.// "STOP_REPLICA" - Stops replication on a Cloud SQL read replica instance.// "START_REPLICA" - Starts replication on a Cloud SQL read replica instance.// "PROMOTE_REPLICA" - Promotes a Cloud SQL replica instance.// "CREATE_REPLICA" - Creates a Cloud SQL replica instance.// "CREATE_USER" - Creates a new user in a Cloud SQL instance.// "DELETE_USER" - Deletes a user from a Cloud SQL instance.// "UPDATE_USER" - Updates an existing user in a Cloud SQL instance.// "CREATE_DATABASE" - Creates a database in the Cloud SQL instance.// "DELETE_DATABASE" - Deletes a database in the Cloud SQL instance.// "UPDATE_DATABASE" - Updates a database in the Cloud SQL instance.// "FAILOVER" - Performs failover of an HA-enabled Cloud SQL failover// replica.// "DELETE_BACKUP" - Deletes the backup taken by a backup run.// "RECREATE_REPLICA"// "TRUNCATE_LOG" - Truncates a general or slow log table in MySQL.// "DEMOTE_MASTER" - Demotes the stand-alone instance to be a Cloud SQL read// replica for an external database server.// "MAINTENANCE" - Indicates that the instance is currently in maintenance.// Maintenance typically causes the instance to be unavailable for 1-3 minutes.// "ENABLE_PRIVATE_IP" - This field is deprecated, and will be removed in// future version of API.// "DEFER_MAINTENANCE"// "CREATE_CLONE" - Creates clone instance.// "RESCHEDULE_MAINTENANCE" - Reschedule maintenance to another time.// "START_EXTERNAL_SYNC" - Starts external sync of a Cloud SQL EM replica to// an external primary instance.// "LOG_CLEANUP" - Recovers logs from an instance's old data disk.// "AUTO_RESTART" - Performs auto-restart of an HA-enabled Cloud SQL database// for auto recovery.// "REENCRYPT" - Re-encrypts CMEK instances with latest key version.// "SWITCHOVER" - Switches the roles of the primary and replica pair. The// target instance should be the replica.// "UPDATE_BACKUP" - Update a backup.// "ACQUIRE_SSRS_LEASE" - Acquire a lease for the setup of SQL Server// Reporting Services (SSRS).// "RELEASE_SSRS_LEASE" - Release a lease for the setup of SQL Server// Reporting Services (SSRS).// "RECONFIGURE_OLD_PRIMARY" - Reconfigures old primary after a promote// replica operation. Effect of a promote operation to the old primary is// executed in this operation, asynchronously from the promote replica// operation executed to the replica.// "CLUSTER_MAINTENANCE" - Indicates that the instance, its read replicas,// and its cascading replicas are in maintenance. Maintenance typically gets// initiated on groups of replicas first, followed by the primary instance. For// each instance, maintenance typically causes the instance to be unavailable// for 1-3 minutes.// "SELF_SERVICE_MAINTENANCE" - Indicates that the instance (and any of its// replicas) are currently in maintenance. This is initiated as a self-service// request by using SSM. Maintenance typically causes the instance to be// unavailable for 1-3 minutes.// "SWITCHOVER_TO_REPLICA" - Switches a primary instance to a replica. This// operation runs as part of a switchover operation to the original primary// instance.// "MAJOR_VERSION_UPGRADE" - Updates the major version of a Cloud SQL// instance.// "ADVANCED_BACKUP" - Deprecated: ADVANCED_BACKUP is deprecated. Use// ENHANCED_BACKUP instead.// "MANAGE_BACKUP" - Changes the BackupTier of a Cloud SQL instance.// "ENHANCED_BACKUP" - Creates a backup for an Enhanced BackupTier Cloud SQL// instance.// "REPAIR_READ_POOL" - Repairs entire read pool or specified read pool nodes// in the read pool.// "CREATE_READ_POOL" - Creates a Cloud SQL read pool instance.OperationTypestring `json:"operationType,omitempty"`// PreCheckMajorVersionUpgradeContext: This field is only populated when the// operation_type is PRE_CHECK_MAJOR_VERSION_UPGRADE. The// PreCheckMajorVersionUpgradeContext message itself contains the details for// that pre-check, such as the target database version for the upgrade and the// results of the check (including any warnings or errors found).PreCheckMajorVersionUpgradeContext *PreCheckMajorVersionUpgradeContext `json:"preCheckMajorVersionUpgradeContext,omitempty"`// SelfLink: The URI of this resource.SelfLinkstring `json:"selfLink,omitempty"`// StartTime: The time this operation actually started in UTC timezone in RFC// 3339 (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.StartTimestring `json:"startTime,omitempty"`// Status: The status of an operation.//// Possible values:// "SQL_OPERATION_STATUS_UNSPECIFIED" - The state of the operation is// unknown.// "PENDING" - The operation has been queued, but has not started yet.// "RUNNING" - The operation is running.// "DONE" - The operation completed.Statusstring `json:"status,omitempty"`// SubOperationType: Optional. The sub operation based on the operation type.SubOperationType *SqlSubOperationType `json:"subOperationType,omitempty"`// TargetId: Name of the resource on which this operation runs.TargetIdstring `json:"targetId,omitempty"`TargetLinkstring `json:"targetLink,omitempty"`// TargetProject: The project ID of the target instance related to this// operation.TargetProjectstring `json:"targetProject,omitempty"`// User: The email address of the user who initiated this operation.Userstring `json:"user,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "AcquireSsrsLeaseContext") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AcquireSsrsLeaseContext") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Operation: An Operation resource. For successful operations that return anOperation resource, only the fields relevant to the operation are populatedin the resource.
func (Operation)MarshalJSON¶added inv0.52.0
typeOperationError¶added inv0.52.0
type OperationError struct {// Code: Identifies the specific error that occurred.Codestring `json:"code,omitempty"`// Kind: This is always `sql#operationError`.Kindstring `json:"kind,omitempty"`// Message: Additional information about the error encountered.Messagestring `json:"message,omitempty"`// ForceSendFields is a list of field names (e.g. "Code") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Code") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}OperationError: Database instance operation error.
func (OperationError)MarshalJSON¶added inv0.52.0
func (sOperationError) MarshalJSON() ([]byte,error)
typeOperationErrors¶added inv0.52.0
type OperationErrors struct {// Errors: The list of errors encountered while processing this operation.Errors []*OperationError `json:"errors,omitempty"`// Kind: This is always `sql#operationErrors`.Kindstring `json:"kind,omitempty"`// ForceSendFields is a list of field names (e.g. "Errors") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Errors") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}OperationErrors: Database instance operation errors list wrapper.
func (OperationErrors)MarshalJSON¶added inv0.52.0
func (sOperationErrors) MarshalJSON() ([]byte,error)
typeOperationMetadata¶added inv0.112.0
type OperationMetadata struct {// ApiVersion: Output only. API version used to start the operation.ApiVersionstring `json:"apiVersion,omitempty"`// CancelRequested: Output only. Identifies whether the user has requested// cancellation of the operation. Operations that have been cancelled// successfully have google.longrunning.Operation.error value with a// google.rpc.Status.code of `1`, corresponding to `Code.CANCELLED`.CancelRequestedbool `json:"cancelRequested,omitempty"`// CreateTime: Output only. The time the operation was created.CreateTimestring `json:"createTime,omitempty"`// EndTime: Output only. The time the operation finished running.EndTimestring `json:"endTime,omitempty"`// StatusDetail: Output only. Human-readable status of the operation, if any.StatusDetailstring `json:"statusDetail,omitempty"`// Target: Output only. Server-defined resource path for the target of the// operation.Targetstring `json:"target,omitempty"`// Verb: Output only. Name of the verb executed by the operation.Verbstring `json:"verb,omitempty"`// ForceSendFields is a list of field names (e.g. "ApiVersion") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ApiVersion") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}OperationMetadata: Represents the metadata of the long-running operation.
func (OperationMetadata)MarshalJSON¶added inv0.112.0
func (sOperationMetadata) MarshalJSON() ([]byte,error)
typeOperationsCancelCall¶added inv0.126.0
type OperationsCancelCall struct {// contains filtered or unexported fields}func (*OperationsCancelCall)Context¶added inv0.126.0
func (c *OperationsCancelCall) Context(ctxcontext.Context) *OperationsCancelCall
Context sets the context to be used in this call's Do method.
func (*OperationsCancelCall)Do¶added inv0.126.0
func (c *OperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty,error)
Do executes the "sql.operations.cancel" call.Any non-2xx status code is an error. Response headers are in either*Empty.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*OperationsCancelCall)Fields¶added inv0.126.0
func (c *OperationsCancelCall) Fields(s ...googleapi.Field) *OperationsCancelCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*OperationsCancelCall)Header¶added inv0.126.0
func (c *OperationsCancelCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeOperationsGetCall¶added inv0.52.0
type OperationsGetCall struct {// contains filtered or unexported fields}func (*OperationsGetCall)Context¶added inv0.52.0
func (c *OperationsGetCall) Context(ctxcontext.Context) *OperationsGetCall
Context sets the context to be used in this call's Do method.
func (*OperationsGetCall)Do¶added inv0.52.0
func (c *OperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.operations.get" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*OperationsGetCall)Fields¶added inv0.52.0
func (c *OperationsGetCall) Fields(s ...googleapi.Field) *OperationsGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*OperationsGetCall)Header¶added inv0.52.0
func (c *OperationsGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*OperationsGetCall)IfNoneMatch¶added inv0.52.0
func (c *OperationsGetCall) IfNoneMatch(entityTagstring) *OperationsGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeOperationsListCall¶added inv0.52.0
type OperationsListCall struct {// contains filtered or unexported fields}func (*OperationsListCall)Context¶added inv0.52.0
func (c *OperationsListCall) Context(ctxcontext.Context) *OperationsListCall
Context sets the context to be used in this call's Do method.
func (*OperationsListCall)Do¶added inv0.52.0
func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*OperationsListResponse,error)
Do executes the "sql.operations.list" call.Any non-2xx status code is an error. Response headers are in either*OperationsListResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*OperationsListCall)Fields¶added inv0.52.0
func (c *OperationsListCall) Fields(s ...googleapi.Field) *OperationsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*OperationsListCall)Header¶added inv0.52.0
func (c *OperationsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*OperationsListCall)IfNoneMatch¶added inv0.52.0
func (c *OperationsListCall) IfNoneMatch(entityTagstring) *OperationsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*OperationsListCall)Instance¶added inv0.52.0
func (c *OperationsListCall) Instance(instancestring) *OperationsListCall
Instance sets the optional parameter "instance": Cloud SQL instance ID. Thisdoes not include the project ID.
func (*OperationsListCall)MaxResults¶added inv0.52.0
func (c *OperationsListCall) MaxResults(maxResultsint64) *OperationsListCall
MaxResults sets the optional parameter "maxResults": Maximum number ofoperations per response.
func (*OperationsListCall)PageToken¶added inv0.52.0
func (c *OperationsListCall) PageToken(pageTokenstring) *OperationsListCall
PageToken sets the optional parameter "pageToken": A previously-returnedpage token representing part of the larger set of results to view.
func (*OperationsListCall)Pages¶added inv0.52.0
func (c *OperationsListCall) Pages(ctxcontext.Context, f func(*OperationsListResponse)error)error
Pages invokes f for each page of results.A non-nil error returned from f will halt the iteration.The provided context supersedes any context provided to the Context method.
typeOperationsListResponse¶added inv0.52.0
type OperationsListResponse struct {// Items: List of operation resources.Items []*Operation `json:"items,omitempty"`// Kind: This is always `sql#operationsList`.Kindstring `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.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}OperationsListResponse: Operations list response.
func (OperationsListResponse)MarshalJSON¶added inv0.52.0
func (sOperationsListResponse) MarshalJSON() ([]byte,error)
typeOperationsService¶added inv0.52.0
type OperationsService struct {// contains filtered or unexported fields}funcNewOperationsService¶added inv0.52.0
func NewOperationsService(s *Service) *OperationsService
func (*OperationsService)Cancel¶added inv0.126.0
func (r *OperationsService) Cancel(projectstring, operationstring) *OperationsCancelCall
Cancel: Cancels an instance operation that has been performed on aninstance.
- operation: Instance operation ID.- project: Project ID of the project that contains the instance.
func (*OperationsService)Get¶added inv0.52.0
func (r *OperationsService) Get(projectstring, operationstring) *OperationsGetCall
Get: Retrieves an instance operation that has been performed on an instance.
- operation: Instance operation ID.- project: Project ID of the project that contains the instance.
func (*OperationsService)List¶added inv0.52.0
func (r *OperationsService) List(projectstring) *OperationsListCall
List: Lists all instance operations that have been performed on the givenCloud SQL instance in the reverse chronological order of the start time.
- project: Project ID of the project that contains the instance.
typePasswordStatus¶added inv0.61.0
type PasswordStatus struct {// Locked: If true, user does not have login privileges.Lockedbool `json:"locked,omitempty"`// PasswordExpirationTime: The expiration time of the current password.PasswordExpirationTimestring `json:"passwordExpirationTime,omitempty"`// ForceSendFields is a list of field names (e.g. "Locked") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Locked") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PasswordStatus: Read-only password status.
func (PasswordStatus)MarshalJSON¶added inv0.61.0
func (sPasswordStatus) MarshalJSON() ([]byte,error)
typePasswordValidationPolicy¶added inv0.61.0
type PasswordValidationPolicy struct {// Complexity: The complexity of the password.//// Possible values:// "COMPLEXITY_UNSPECIFIED" - Complexity check is not specified.// "COMPLEXITY_DEFAULT" - A combination of lowercase, uppercase, numeric, and// non-alphanumeric characters.Complexitystring `json:"complexity,omitempty"`// DisallowCompromisedCredentials: This field is deprecated and will be removed// in a future version of the API.DisallowCompromisedCredentialsbool `json:"disallowCompromisedCredentials,omitempty"`// DisallowUsernameSubstring: Disallow username as a part of the password.DisallowUsernameSubstringbool `json:"disallowUsernameSubstring,omitempty"`// EnablePasswordPolicy: Whether the password policy is enabled or not.EnablePasswordPolicybool `json:"enablePasswordPolicy,omitempty"`// MinLength: Minimum number of characters allowed.MinLengthint64 `json:"minLength,omitempty"`// PasswordChangeInterval: Minimum interval after which the password can be// changed. This flag is only supported for PostgreSQL.PasswordChangeIntervalstring `json:"passwordChangeInterval,omitempty"`// ReuseInterval: Number of previous passwords that cannot be reused.ReuseIntervalint64 `json:"reuseInterval,omitempty"`// ForceSendFields is a list of field names (e.g. "Complexity") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Complexity") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PasswordValidationPolicy: Database instance local user password validationpolicy
func (PasswordValidationPolicy)MarshalJSON¶added inv0.61.0
func (sPasswordValidationPolicy) MarshalJSON() ([]byte,error)
typePerformDiskShrinkContext¶added inv0.114.0
type PerformDiskShrinkContext struct {// TargetSizeGb: The target disk shrink size in GigaBytes.TargetSizeGbint64 `json:"targetSizeGb,omitempty,string"`// ForceSendFields is a list of field names (e.g. "TargetSizeGb") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "TargetSizeGb") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PerformDiskShrinkContext: Perform disk shrink context.
func (PerformDiskShrinkContext)MarshalJSON¶added inv0.114.0
func (sPerformDiskShrinkContext) MarshalJSON() ([]byte,error)
typePointInTimeRestoreContext¶added inv0.232.0
type PointInTimeRestoreContext struct {// AllocatedIpRange: Optional. The name of the allocated IP range for the// internal IP Cloud SQL instance. For example:// "google-managed-services-default". If you set this, then Cloud SQL creates// the IP address for the cloned instance in the allocated range. This range// must comply withRFC 1035 (https://tools.ietf.org/html/rfc1035) standards.// Specifically, the name must be 1-63 characters long and match the regular// expression a-z ([-a-z0-9]*[a-z0-9])?. Reserved for future use.AllocatedIpRangestring `json:"allocatedIpRange,omitempty"`// Datasource: The Backup and Disaster Recovery (DR) Service Datasource URI.// Format:// projects/{project}/locations/{region}/backupVaults/{backupvault}/dataSources/// {datasource}.Datasourcestring `json:"datasource,omitempty"`// PointInTime: Required. The date and time to which you want to restore the// instance.PointInTimestring `json:"pointInTime,omitempty"`// PreferredSecondaryZone: Optional. Point-in-time recovery of a regional// instance in the specified zones. If not specified, clone to the same// secondary zone as the source instance. This value cannot be the same as the// preferred_zone field.PreferredSecondaryZonestring `json:"preferredSecondaryZone,omitempty"`// PreferredZone: Optional. Point-in-time recovery of an instance to the// specified zone. If no zone is specified, then clone to the same primary zone// as the source instance.PreferredZonestring `json:"preferredZone,omitempty"`// PrivateNetwork: Optional. The resource link for the VPC network from which// the Cloud SQL instance is accessible for private IP. For example,// `/projects/myProject/global/networks/default`.PrivateNetworkstring `json:"privateNetwork,omitempty"`// TargetInstance: Target instance name.TargetInstancestring `json:"targetInstance,omitempty"`// ForceSendFields is a list of field names (e.g. "AllocatedIpRange") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AllocatedIpRange") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PointInTimeRestoreContext: The context to perform a point-in-time recoveryof an instance managed by Backup and Disaster Recovery (DR) Service.
func (PointInTimeRestoreContext)MarshalJSON¶added inv0.232.0
func (sPointInTimeRestoreContext) MarshalJSON() ([]byte,error)
typePoolNodeConfig¶added inv0.227.0
type PoolNodeConfig struct {// DnsName: Output only. The DNS name of the read pool node.DnsNamestring `json:"dnsName,omitempty"`// DnsNames: Output only. The list of DNS names used by this read pool node.DnsNames []*DnsNameMapping `json:"dnsNames,omitempty"`// GceZone: Output only. The zone of the read pool node.GceZonestring `json:"gceZone,omitempty"`// IpAddresses: Output only. Mappings containing IP addresses that can be used// to connect to the read pool node.IpAddresses []*IpMapping `json:"ipAddresses,omitempty"`// Name: Output only. The name of the read pool node, to be used for retrieving// metrics and logs.Namestring `json:"name,omitempty"`// State: Output only. The current state of the read pool node.//// Possible values:// "SQL_INSTANCE_STATE_UNSPECIFIED" - The state of the instance is unknown.// "RUNNABLE" - The instance is running, or has been stopped by owner.// "SUSPENDED" - The instance is not available, for example due to problems// with billing.// "PENDING_DELETE" - The instance is being deleted.// "PENDING_CREATE" - The instance is being created.// "MAINTENANCE" - The instance is down for maintenance.// "FAILED" - The creation of the instance failed or a fatal error occurred// during maintenance.// "ONLINE_MAINTENANCE" - Deprecated// "REPAIRING" - (Applicable to read pool nodes only.) The read pool node// needs to be repaired. The database might be unavailable.Statestring `json:"state,omitempty"`// ForceSendFields is a list of field names (e.g. "DnsName") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DnsName") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PoolNodeConfig: Details of a single read pool node of a read pool.
func (PoolNodeConfig)MarshalJSON¶added inv0.227.0
func (sPoolNodeConfig) MarshalJSON() ([]byte,error)
typePreCheckMajorVersionUpgradeContext¶added inv0.250.0
type PreCheckMajorVersionUpgradeContext struct {// Kind: Optional. This is always `sql#preCheckMajorVersionUpgradeContext`.Kindstring `json:"kind,omitempty"`// PreCheckResponse: Output only. The responses from the precheck operation.PreCheckResponse []*PreCheckResponse `json:"preCheckResponse,omitempty"`// TargetDatabaseVersion: Required. The target database version to upgrade to.//// Possible values:// "SQL_DATABASE_VERSION_UNSPECIFIED" - This is an unknown database version.// "MYSQL_5_1" - The database version is MySQL 5.1.// "MYSQL_5_5" - The database version is MySQL 5.5.// "MYSQL_5_6" - The database version is MySQL 5.6.// "MYSQL_5_7" - The database version is MySQL 5.7.// "MYSQL_8_0" - The database version is MySQL 8.// "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor// version is 18.// "MYSQL_8_0_26" - The database major version is MySQL 8.0 and the minor// version is 26.// "MYSQL_8_0_27" - The database major version is MySQL 8.0 and the minor// version is 27.// "MYSQL_8_0_28" - The database major version is MySQL 8.0 and the minor// version is 28.// "MYSQL_8_0_29" - The database major version is MySQL 8.0 and the minor// version is 29.// "MYSQL_8_0_30" - The database major version is MySQL 8.0 and the minor// version is 30.// "MYSQL_8_0_31" - The database major version is MySQL 8.0 and the minor// version is 31.// "MYSQL_8_0_32" - The database major version is MySQL 8.0 and the minor// version is 32.// "MYSQL_8_0_33" - The database major version is MySQL 8.0 and the minor// version is 33.// "MYSQL_8_0_34" - The database major version is MySQL 8.0 and the minor// version is 34.// "MYSQL_8_0_35" - The database major version is MySQL 8.0 and the minor// version is 35.// "MYSQL_8_0_36" - The database major version is MySQL 8.0 and the minor// version is 36.// "MYSQL_8_0_37" - The database major version is MySQL 8.0 and the minor// version is 37.// "MYSQL_8_0_39" - The database major version is MySQL 8.0 and the minor// version is 39.// "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor// version is 40.// "MYSQL_8_0_41" - The database major version is MySQL 8.0 and the minor// version is 41.// "MYSQL_8_0_42" - The database major version is MySQL 8.0 and the minor// version is 42.// "MYSQL_8_0_43" - The database major version is MySQL 8.0 and the minor// version is 43.// "MYSQL_8_0_44" - The database major version is MySQL 8.0 and the minor// version is 44.// "MYSQL_8_0_45" - The database major version is MySQL 8.0 and the minor// version is 45.// "MYSQL_8_0_46" - The database major version is MySQL 8.0 and the minor// version is 46.// "MYSQL_8_4" - The database version is MySQL 8.4.// "SQLSERVER_2017_STANDARD" - The database version is SQL Server 2017// Standard.// "SQLSERVER_2017_ENTERPRISE" - The database version is SQL Server 2017// Enterprise.// "SQLSERVER_2017_EXPRESS" - The database version is SQL Server 2017// Express.// "SQLSERVER_2017_WEB" - The database version is SQL Server 2017 Web.// "POSTGRES_9_6" - The database version is PostgreSQL 9.6.// "POSTGRES_10" - The database version is PostgreSQL 10.// "POSTGRES_11" - The database version is PostgreSQL 11.// "POSTGRES_12" - The database version is PostgreSQL 12.// "POSTGRES_13" - The database version is PostgreSQL 13.// "POSTGRES_14" - The database version is PostgreSQL 14.// "POSTGRES_15" - The database version is PostgreSQL 15.// "POSTGRES_16" - The database version is PostgreSQL 16.// "POSTGRES_17" - The database version is PostgreSQL 17.// "POSTGRES_18" - The database version is PostgreSQL 18.// "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019// Standard.// "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019// Enterprise.// "SQLSERVER_2019_EXPRESS" - The database version is SQL Server 2019// Express.// "SQLSERVER_2019_WEB" - The database version is SQL Server 2019 Web.// "SQLSERVER_2022_STANDARD" - The database version is SQL Server 2022// Standard.// "SQLSERVER_2022_ENTERPRISE" - The database version is SQL Server 2022// Enterprise.// "SQLSERVER_2022_EXPRESS" - The database version is SQL Server 2022// Express.// "SQLSERVER_2022_WEB" - The database version is SQL Server 2022 Web.TargetDatabaseVersionstring `json:"targetDatabaseVersion,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PreCheckMajorVersionUpgradeContext: Pre-check major version upgrade context.
func (PreCheckMajorVersionUpgradeContext)MarshalJSON¶added inv0.250.0
func (sPreCheckMajorVersionUpgradeContext) MarshalJSON() ([]byte,error)
typePreCheckResponse¶added inv0.250.0
type PreCheckResponse struct {// ActionsRequired: The actions that the user needs to take. Use repeated for// multiple actions.ActionsRequired []string `json:"actionsRequired,omitempty"`// Message: The message to be displayed to the user.Messagestring `json:"message,omitempty"`// MessageType: The type of message whether it is an info, warning, or error.//// Possible values:// "MESSAGE_TYPE_UNSPECIFIED" - Default unspecified value to prevent// unintended behavior changes.// "INFO" - General informational messages that don't require action.// "WARNING" - Warnings that might impact the upgrade but don't block it.// "ERROR" - Errors that a user must resolve before proceeding with the// upgrade.MessageTypestring `json:"messageType,omitempty"`// ForceSendFields is a list of field names (e.g. "ActionsRequired") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ActionsRequired") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PreCheckResponse: Structured PreCheckResponse containing message, type, andrequired actions.
func (PreCheckResponse)MarshalJSON¶added inv0.250.0
func (sPreCheckResponse) MarshalJSON() ([]byte,error)
typeProjectsInstancesGetDiskShrinkConfigCall¶added inv0.114.0
type ProjectsInstancesGetDiskShrinkConfigCall struct {// contains filtered or unexported fields}func (*ProjectsInstancesGetDiskShrinkConfigCall)Context¶added inv0.114.0
func (c *ProjectsInstancesGetDiskShrinkConfigCall) Context(ctxcontext.Context) *ProjectsInstancesGetDiskShrinkConfigCall
Context sets the context to be used in this call's Do method.
func (*ProjectsInstancesGetDiskShrinkConfigCall)Do¶added inv0.114.0
func (c *ProjectsInstancesGetDiskShrinkConfigCall) Do(opts ...googleapi.CallOption) (*SqlInstancesGetDiskShrinkConfigResponse,error)
Do executes the "sql.projects.instances.getDiskShrinkConfig" call.Any non-2xx status code is an error. Response headers are in either*SqlInstancesGetDiskShrinkConfigResponse.ServerResponse.Header or (if aresponse was returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*ProjectsInstancesGetDiskShrinkConfigCall)Fields¶added inv0.114.0
func (c *ProjectsInstancesGetDiskShrinkConfigCall) Fields(s ...googleapi.Field) *ProjectsInstancesGetDiskShrinkConfigCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsInstancesGetDiskShrinkConfigCall)Header¶added inv0.114.0
func (c *ProjectsInstancesGetDiskShrinkConfigCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsInstancesGetDiskShrinkConfigCall)IfNoneMatch¶added inv0.114.0
func (c *ProjectsInstancesGetDiskShrinkConfigCall) IfNoneMatch(entityTagstring) *ProjectsInstancesGetDiskShrinkConfigCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeProjectsInstancesGetLatestRecoveryTimeCall¶added inv0.130.0
type ProjectsInstancesGetLatestRecoveryTimeCall struct {// contains filtered or unexported fields}func (*ProjectsInstancesGetLatestRecoveryTimeCall)Context¶added inv0.130.0
func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Context(ctxcontext.Context) *ProjectsInstancesGetLatestRecoveryTimeCall
Context sets the context to be used in this call's Do method.
func (*ProjectsInstancesGetLatestRecoveryTimeCall)Do¶added inv0.130.0
func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Do(opts ...googleapi.CallOption) (*SqlInstancesGetLatestRecoveryTimeResponse,error)
Do executes the "sql.projects.instances.getLatestRecoveryTime" call.Any non-2xx status code is an error. Response headers are in either*SqlInstancesGetLatestRecoveryTimeResponse.ServerResponse.Header or (if aresponse was returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*ProjectsInstancesGetLatestRecoveryTimeCall)Fields¶added inv0.130.0
func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Fields(s ...googleapi.Field) *ProjectsInstancesGetLatestRecoveryTimeCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsInstancesGetLatestRecoveryTimeCall)Header¶added inv0.130.0
func (c *ProjectsInstancesGetLatestRecoveryTimeCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*ProjectsInstancesGetLatestRecoveryTimeCall)IfNoneMatch¶added inv0.130.0
func (c *ProjectsInstancesGetLatestRecoveryTimeCall) IfNoneMatch(entityTagstring) *ProjectsInstancesGetLatestRecoveryTimeCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
func (*ProjectsInstancesGetLatestRecoveryTimeCall)SourceInstanceDeletionTime¶added inv0.248.0
func (c *ProjectsInstancesGetLatestRecoveryTimeCall) SourceInstanceDeletionTime(sourceInstanceDeletionTimestring) *ProjectsInstancesGetLatestRecoveryTimeCall
SourceInstanceDeletionTime sets the optional parameter"sourceInstanceDeletionTime": The timestamp used to identify the time whenthe source instance is deleted. If this instance is deleted, then you mustset the timestamp.
typeProjectsInstancesPerformDiskShrinkCall¶added inv0.114.0
type ProjectsInstancesPerformDiskShrinkCall struct {// contains filtered or unexported fields}func (*ProjectsInstancesPerformDiskShrinkCall)Context¶added inv0.114.0
func (c *ProjectsInstancesPerformDiskShrinkCall) Context(ctxcontext.Context) *ProjectsInstancesPerformDiskShrinkCall
Context sets the context to be used in this call's Do method.
func (*ProjectsInstancesPerformDiskShrinkCall)Do¶added inv0.114.0
func (c *ProjectsInstancesPerformDiskShrinkCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.projects.instances.performDiskShrink" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsInstancesPerformDiskShrinkCall)Fields¶added inv0.114.0
func (c *ProjectsInstancesPerformDiskShrinkCall) Fields(s ...googleapi.Field) *ProjectsInstancesPerformDiskShrinkCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsInstancesPerformDiskShrinkCall)Header¶added inv0.114.0
func (c *ProjectsInstancesPerformDiskShrinkCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsInstancesRescheduleMaintenanceCall¶added inv0.52.0
type ProjectsInstancesRescheduleMaintenanceCall struct {// contains filtered or unexported fields}func (*ProjectsInstancesRescheduleMaintenanceCall)Context¶added inv0.52.0
func (c *ProjectsInstancesRescheduleMaintenanceCall) Context(ctxcontext.Context) *ProjectsInstancesRescheduleMaintenanceCall
Context sets the context to be used in this call's Do method.
func (*ProjectsInstancesRescheduleMaintenanceCall)Do¶added inv0.52.0
func (c *ProjectsInstancesRescheduleMaintenanceCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.projects.instances.rescheduleMaintenance" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsInstancesRescheduleMaintenanceCall)Fields¶added inv0.52.0
func (c *ProjectsInstancesRescheduleMaintenanceCall) Fields(s ...googleapi.Field) *ProjectsInstancesRescheduleMaintenanceCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsInstancesRescheduleMaintenanceCall)Header¶added inv0.52.0
func (c *ProjectsInstancesRescheduleMaintenanceCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsInstancesResetReplicaSizeCall¶added inv0.114.0
type ProjectsInstancesResetReplicaSizeCall struct {// contains filtered or unexported fields}func (*ProjectsInstancesResetReplicaSizeCall)Context¶added inv0.114.0
func (c *ProjectsInstancesResetReplicaSizeCall) Context(ctxcontext.Context) *ProjectsInstancesResetReplicaSizeCall
Context sets the context to be used in this call's Do method.
func (*ProjectsInstancesResetReplicaSizeCall)Do¶added inv0.114.0
func (c *ProjectsInstancesResetReplicaSizeCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.projects.instances.resetReplicaSize" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsInstancesResetReplicaSizeCall)Fields¶added inv0.114.0
func (c *ProjectsInstancesResetReplicaSizeCall) Fields(s ...googleapi.Field) *ProjectsInstancesResetReplicaSizeCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsInstancesResetReplicaSizeCall)Header¶added inv0.114.0
func (c *ProjectsInstancesResetReplicaSizeCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsInstancesService¶
type ProjectsInstancesService struct {// contains filtered or unexported fields}funcNewProjectsInstancesService¶
func NewProjectsInstancesService(s *Service) *ProjectsInstancesService
func (*ProjectsInstancesService)GetDiskShrinkConfig¶added inv0.114.0
func (r *ProjectsInstancesService) GetDiskShrinkConfig(projectstring, instancestring) *ProjectsInstancesGetDiskShrinkConfigCall
GetDiskShrinkConfig: Get Disk Shrink Config for a given instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*ProjectsInstancesService)GetLatestRecoveryTime¶added inv0.130.0
func (r *ProjectsInstancesService) GetLatestRecoveryTime(projectstring, instancestring) *ProjectsInstancesGetLatestRecoveryTimeCall
GetLatestRecoveryTime: Get Latest Recovery Time for a given instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*ProjectsInstancesService)PerformDiskShrink¶added inv0.114.0
func (r *ProjectsInstancesService) PerformDiskShrink(projectstring, instancestring, performdiskshrinkcontext *PerformDiskShrinkContext) *ProjectsInstancesPerformDiskShrinkCall
PerformDiskShrink: Perform Disk Shrink on primary instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*ProjectsInstancesService)RescheduleMaintenance¶added inv0.52.0
func (r *ProjectsInstancesService) RescheduleMaintenance(projectstring, instancestring, sqlinstancesreschedulemaintenancerequestbody *SqlInstancesRescheduleMaintenanceRequestBody) *ProjectsInstancesRescheduleMaintenanceCall
RescheduleMaintenance: Reschedules the maintenance on the given instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: ID of the project that contains the instance.
func (*ProjectsInstancesService)ResetReplicaSize¶added inv0.114.0
func (r *ProjectsInstancesService) ResetReplicaSize(projectstring, instancestring, sqlinstancesresetreplicasizerequest *SqlInstancesResetReplicaSizeRequest) *ProjectsInstancesResetReplicaSizeCall
ResetReplicaSize: Reset Replica Size to primary instance disk size.
- instance: Cloud SQL read replica instance name.- project: ID of the project that contains the read replica.
func (*ProjectsInstancesService)StartExternalSync¶added inv0.52.0
func (r *ProjectsInstancesService) StartExternalSync(projectstring, instancestring, sqlinstancesstartexternalsyncrequest *SqlInstancesStartExternalSyncRequest) *ProjectsInstancesStartExternalSyncCall
StartExternalSync: Start External primary instance migration.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: ID of the project that contains the instance.
func (*ProjectsInstancesService)VerifyExternalSyncSettings¶added inv0.52.0
func (r *ProjectsInstancesService) VerifyExternalSyncSettings(projectstring, instancestring, sqlinstancesverifyexternalsyncsettingsrequest *SqlInstancesVerifyExternalSyncSettingsRequest) *ProjectsInstancesVerifyExternalSyncSettingsCall
VerifyExternalSyncSettings: Verify External primary instance external syncsettings.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
typeProjectsInstancesStartExternalSyncCall¶added inv0.52.0
type ProjectsInstancesStartExternalSyncCall struct {// contains filtered or unexported fields}func (*ProjectsInstancesStartExternalSyncCall)Context¶added inv0.52.0
func (c *ProjectsInstancesStartExternalSyncCall) Context(ctxcontext.Context) *ProjectsInstancesStartExternalSyncCall
Context sets the context to be used in this call's Do method.
func (*ProjectsInstancesStartExternalSyncCall)Do¶added inv0.52.0
func (c *ProjectsInstancesStartExternalSyncCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.projects.instances.startExternalSync" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*ProjectsInstancesStartExternalSyncCall)Fields¶added inv0.52.0
func (c *ProjectsInstancesStartExternalSyncCall) Fields(s ...googleapi.Field) *ProjectsInstancesStartExternalSyncCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsInstancesStartExternalSyncCall)Header¶added inv0.52.0
func (c *ProjectsInstancesStartExternalSyncCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsInstancesVerifyExternalSyncSettingsCall¶added inv0.52.0
type ProjectsInstancesVerifyExternalSyncSettingsCall struct {// contains filtered or unexported fields}func (*ProjectsInstancesVerifyExternalSyncSettingsCall)Context¶added inv0.52.0
func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Context(ctxcontext.Context) *ProjectsInstancesVerifyExternalSyncSettingsCall
Context sets the context to be used in this call's Do method.
func (*ProjectsInstancesVerifyExternalSyncSettingsCall)Do¶added inv0.52.0
func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Do(opts ...googleapi.CallOption) (*SqlInstancesVerifyExternalSyncSettingsResponse,error)
Do executes the "sql.projects.instances.verifyExternalSyncSettings" call.Any non-2xx status code is an error. Response headers are in either*SqlInstancesVerifyExternalSyncSettingsResponse.ServerResponse.Header or (ifa response was returned at all) in error.(*googleapi.Error).Header. Usegoogleapi.IsNotModified to check whether the returned error was becausehttp.StatusNotModified was returned.
func (*ProjectsInstancesVerifyExternalSyncSettingsCall)Fields¶added inv0.52.0
func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Fields(s ...googleapi.Field) *ProjectsInstancesVerifyExternalSyncSettingsCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*ProjectsInstancesVerifyExternalSyncSettingsCall)Header¶added inv0.52.0
func (c *ProjectsInstancesVerifyExternalSyncSettingsCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeProjectsService¶
type ProjectsService struct {Instances *ProjectsInstancesService// contains filtered or unexported fields}funcNewProjectsService¶
func NewProjectsService(s *Service) *ProjectsService
typePscAutoConnectionConfig¶added inv0.201.0
type PscAutoConnectionConfig struct {// ConsumerNetwork: Optional. The consumer network of this consumer endpoint.// This must be a resource path that includes both the host project and the// network name. For example, `projects/project1/global/networks/network1`. The// consumer host project of this network might be different from the consumer// service project.ConsumerNetworkstring `json:"consumerNetwork,omitempty"`// ConsumerNetworkStatus: The connection policy status of the consumer network.ConsumerNetworkStatusstring `json:"consumerNetworkStatus,omitempty"`// ConsumerProject: Optional. This is the project ID of consumer service// project of this consumer endpoint. Optional. This is only applicable if// consumer_network is a shared vpc network.ConsumerProjectstring `json:"consumerProject,omitempty"`// IpAddress: The IP address of the consumer endpoint.IpAddressstring `json:"ipAddress,omitempty"`// Status: The connection status of the consumer endpoint.Statusstring `json:"status,omitempty"`// ForceSendFields is a list of field names (e.g. "ConsumerNetwork") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ConsumerNetwork") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PscAutoConnectionConfig: Settings for an automatically-setup Private ServiceConnect consumer endpoint that is used to connect to a Cloud SQL instance.
func (PscAutoConnectionConfig)MarshalJSON¶added inv0.201.0
func (sPscAutoConnectionConfig) MarshalJSON() ([]byte,error)
typePscConfig¶added inv0.135.0
type PscConfig struct {// AllowedConsumerProjects: Optional. The list of consumer projects that are// allow-listed for PSC connections to this instance. This instance can be// connected to with PSC from any network in these projects. Each consumer// project in this list may be represented by a project number (numeric) or by// a project id (alphanumeric).AllowedConsumerProjects []string `json:"allowedConsumerProjects,omitempty"`// NetworkAttachmentUri: Optional. The network attachment of the consumer// network that the Private Service Connect enabled Cloud SQL instance is// authorized to connect via PSC interface. format:// projects/PROJECT/regions/REGION/networkAttachments/IDNetworkAttachmentUristring `json:"networkAttachmentUri,omitempty"`// PscAutoConnections: Optional. The list of settings for requested Private// Service Connect consumer endpoints that can be used to connect to this Cloud// SQL instance.PscAutoConnections []*PscAutoConnectionConfig `json:"pscAutoConnections,omitempty"`// PscEnabled: Whether PSC connectivity is enabled for this instance.PscEnabledbool `json:"pscEnabled,omitempty"`// ForceSendFields is a list of field names (e.g. "AllowedConsumerProjects") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AllowedConsumerProjects") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}PscConfig: PSC settings for a Cloud SQL instance.
func (PscConfig)MarshalJSON¶added inv0.135.0
typeQueryResult¶added inv0.248.0
type QueryResult struct {// Columns: List of columns included in the result. This also includes the data// type of the column.Columns []*Column `json:"columns,omitempty"`// Message: Message related to the SQL execution result.Messagestring `json:"message,omitempty"`// PartialResult: Set to true if the SQL execution's result is truncated due to// size limits or an error retrieving results.PartialResultbool `json:"partialResult,omitempty"`// Rows: Rows returned by the SQL statement.Rows []*Row `json:"rows,omitempty"`// Status: If results were truncated due to an error, details of that error.Status *Status `json:"status,omitempty"`// ForceSendFields is a list of field names (e.g. "Columns") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Columns") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}QueryResult: QueryResult contains the result of executing a single SQLstatement.
func (QueryResult)MarshalJSON¶added inv0.248.0
func (sQueryResult) MarshalJSON() ([]byte,error)
typeReadPoolAutoScaleConfig¶added inv0.250.0
type ReadPoolAutoScaleConfig struct {// DisableScaleIn: Indicates whether read pool auto scaling supports scale in// operations (removing nodes).DisableScaleInbool `json:"disableScaleIn,omitempty"`// Enabled: Indicates whether read pool auto scaling is enabled.Enabledbool `json:"enabled,omitempty"`// MaxNodeCount: Maximum number of read pool nodes to be maintained.MaxNodeCountint64 `json:"maxNodeCount,omitempty"`// MinNodeCount: Minimum number of read pool nodes to be maintained.MinNodeCountint64 `json:"minNodeCount,omitempty"`// ScaleInCooldownSeconds: The cooldown period for scale-in operations.ScaleInCooldownSecondsint64 `json:"scaleInCooldownSeconds,omitempty"`// ScaleOutCooldownSeconds: The cooldown period for scale-out operations.ScaleOutCooldownSecondsint64 `json:"scaleOutCooldownSeconds,omitempty"`// TargetMetrics: Optional. Target metrics for read pool auto scaling.TargetMetrics []*TargetMetric `json:"targetMetrics,omitempty"`// ForceSendFields is a list of field names (e.g. "DisableScaleIn") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DisableScaleIn") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReadPoolAutoScaleConfig: The read pool auto-scale configuration.
func (ReadPoolAutoScaleConfig)MarshalJSON¶added inv0.250.0
func (sReadPoolAutoScaleConfig) MarshalJSON() ([]byte,error)
typeReplicaConfiguration¶
type ReplicaConfiguration struct {// CascadableReplica: Optional. Specifies if a SQL Server replica is a// cascadable replica. A cascadable replica is a SQL Server cross region// replica that supports replica(s) under it.CascadableReplicabool `json:"cascadableReplica,omitempty"`// FailoverTarget: Specifies if the replica is the failover target. If the// field is set to `true`, the replica will be designated as a failover// replica. In case the primary instance fails, the replica instance will be// promoted as the new primary instance. Only one replica can be specified as// failover target, and the replica has to be in different zone with the// primary instance.FailoverTargetbool `json:"failoverTarget,omitempty"`// Kind: This is always `sql#replicaConfiguration`.Kindstring `json:"kind,omitempty"`// MysqlReplicaConfiguration: MySQL specific configuration when replicating// from a MySQL on-premises primary instance. Replication configuration// information such as the username, password, certificates, and keys are not// stored in the instance metadata. The configuration information is used only// to set up the replication connection and is stored by MySQL in a file named// `master.info` in the data directory.MysqlReplicaConfiguration *MySqlReplicaConfiguration `json:"mysqlReplicaConfiguration,omitempty"`// ForceSendFields is a list of field names (e.g. "CascadableReplica") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CascadableReplica") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReplicaConfiguration: Read-replica configuration for connecting to theprimary instance.
func (ReplicaConfiguration)MarshalJSON¶
func (sReplicaConfiguration) MarshalJSON() ([]byte,error)
typeReplicationCluster¶added inv0.172.0
type ReplicationCluster struct {// DrReplica: Output only. Read-only field that indicates whether the replica// is a DR replica. This field is not set if the instance is a primary// instance.DrReplicabool `json:"drReplica,omitempty"`// FailoverDrReplicaName: Optional. If the instance is a primary instance, then// this field identifies the disaster recovery (DR) replica. A DR replica is an// optional configuration for Enterprise Plus edition instances. If the// instance is a read replica, then the field is not set. Set this field to a// replica name to designate a DR replica for a primary instance. Remove the// replica name to remove the DR replica designation.FailoverDrReplicaNamestring `json:"failoverDrReplicaName,omitempty"`// PsaWriteEndpoint: Output only. If set, this field indicates this instance// has a private service access (PSA) DNS endpoint that is pointing to the// primary instance of the cluster. If this instance is the primary, then the// DNS endpoint points to this instance. After a switchover or replica failover// operation, this DNS endpoint points to the promoted instance. This is a// read-only field, returned to the user as information. This field can exist// even if a standalone instance doesn't have a DR replica yet or the DR// replica is deleted.PsaWriteEndpointstring `json:"psaWriteEndpoint,omitempty"`// ForceSendFields is a list of field names (e.g. "DrReplica") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DrReplica") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}ReplicationCluster: A primary instance and disaster recovery (DR) replicapair. A DR replica is a cross-region replica that you designate for failoverin the event that the primary instance experiences regional failure.Applicable to MySQL and PostgreSQL.
func (ReplicationCluster)MarshalJSON¶added inv0.172.0
func (sReplicationCluster) MarshalJSON() ([]byte,error)
typeReschedule¶added inv0.52.0
type Reschedule struct {// RescheduleType: Required. The type of the reschedule.//// Possible values:// "RESCHEDULE_TYPE_UNSPECIFIED"// "IMMEDIATE" - Reschedules maintenance to happen now (within 5 minutes).// "NEXT_AVAILABLE_WINDOW" - Reschedules maintenance to occur within one week// from the originally scheduled day and time.// "SPECIFIC_TIME" - Reschedules maintenance to a specific time and day.RescheduleTypestring `json:"rescheduleType,omitempty"`// ScheduleTime: Optional. Timestamp when the maintenance shall be rescheduled// to if reschedule_type=SPECIFIC_TIME, inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.ScheduleTimestring `json:"scheduleTime,omitempty"`// ForceSendFields is a list of field names (e.g. "RescheduleType") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "RescheduleType") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}func (Reschedule)MarshalJSON¶added inv0.52.0
func (sReschedule) MarshalJSON() ([]byte,error)
typeRestoreBackupContext¶added inv0.52.0
type RestoreBackupContext struct {// BackupRunId: The ID of the backup run to restore from.BackupRunIdint64 `json:"backupRunId,omitempty,string"`// InstanceId: The ID of the instance that the backup was taken from.InstanceIdstring `json:"instanceId,omitempty"`// Kind: This is always `sql#restoreBackupContext`.Kindstring `json:"kind,omitempty"`// Project: The full project ID of the source instance.Projectstring `json:"project,omitempty"`// ForceSendFields is a list of field names (e.g. "BackupRunId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "BackupRunId") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}RestoreBackupContext: Database instance restore from backup context. Backupcontext contains source instance id and project id.
func (RestoreBackupContext)MarshalJSON¶added inv0.52.0
func (sRestoreBackupContext) MarshalJSON() ([]byte,error)
typeRotateEntraIdCertificateContext¶added inv0.257.0
type RotateEntraIdCertificateContext struct {// Kind: Optional. This is always `sql#rotateEntraIdCertificateContext`.Kindstring `json:"kind,omitempty"`// NextVersion: Optional. The fingerprint of the next version to be rotated to.// If left unspecified, will be rotated to the most recently added server// certificate version.NextVersionstring `json:"nextVersion,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}RotateEntraIdCertificateContext: Instance rotate Entra ID certificatecontext.
func (RotateEntraIdCertificateContext)MarshalJSON¶added inv0.257.0
func (sRotateEntraIdCertificateContext) MarshalJSON() ([]byte,error)
typeRotateServerCaContext¶added inv0.52.0
type RotateServerCaContext struct {// Kind: This is always `sql#rotateServerCaContext`.Kindstring `json:"kind,omitempty"`// NextVersion: The fingerprint of the next version to be rotated to. If left// unspecified, will be rotated to the most recently added server CA version.NextVersionstring `json:"nextVersion,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}RotateServerCaContext: Instance rotate server CA context.
func (RotateServerCaContext)MarshalJSON¶added inv0.52.0
func (sRotateServerCaContext) MarshalJSON() ([]byte,error)
typeRotateServerCertificateContext¶added inv0.197.0
type RotateServerCertificateContext struct {// Kind: Optional. This is always `sql#rotateServerCertificateContext`.Kindstring `json:"kind,omitempty"`// NextVersion: The fingerprint of the next version to be rotated to. If left// unspecified, will be rotated to the most recently added server certificate// version.NextVersionstring `json:"nextVersion,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}RotateServerCertificateContext: Instance rotate server certificate context.
func (RotateServerCertificateContext)MarshalJSON¶added inv0.197.0
func (sRotateServerCertificateContext) MarshalJSON() ([]byte,error)
typeRow¶added inv0.248.0
type Row struct {// Values: The values for the row.Values []*Value `json:"values,omitempty"`// ForceSendFields is a list of field names (e.g. "Values") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Values") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Row: Contains the values for a row.
func (Row)MarshalJSON¶added inv0.248.0
typeSelectedObjects¶added inv0.207.0
type SelectedObjects struct {// Database: Required. The name of the database to migrate.Databasestring `json:"database,omitempty"`// ForceSendFields is a list of field names (e.g. "Database") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Database") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SelectedObjects: A list of objects that the user selects for replicationfrom an external source instance.
func (SelectedObjects)MarshalJSON¶added inv0.207.0
func (sSelectedObjects) MarshalJSON() ([]byte,error)
typeService¶
type Service struct {BasePathstring// API endpoint base URLUserAgentstring// optional additional User-Agent fragmentBackups *BackupsServiceBackupRuns *BackupRunsServiceConnect *ConnectServiceDatabases *DatabasesServiceFlags *FlagsServiceInstances *InstancesServiceOperations *OperationsServiceProjects *ProjectsServiceSslCerts *SslCertsServiceTiers *TiersServiceUsers *UsersService// contains filtered or unexported fields} funcNewdeprecated
New creates a new Service. It uses the provided http.Client for requests.
Deprecated: please use NewService instead.To provide a custom HTTP client, use option.WithHTTPClient.If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
funcNewService¶
NewService creates a new Service.
typeSettings¶
type Settings struct {// ActivationPolicy: The activation policy specifies when the instance is// activated; it is applicable only when the instance state is RUNNABLE. Valid// values: * `ALWAYS`: The instance is on, and remains so even in the absence// of connection requests. * `NEVER`: The instance is off; it is not activated,// even if a connection request arrives.//// Possible values:// "SQL_ACTIVATION_POLICY_UNSPECIFIED" - Unknown activation plan.// "ALWAYS" - The instance is always up and running.// "NEVER" - The instance never starts.// "ON_DEMAND" - The instance starts upon receiving requests.ActivationPolicystring `json:"activationPolicy,omitempty"`// ActiveDirectoryConfig: Active Directory configuration, relevant only for// Cloud SQL for SQL Server.ActiveDirectoryConfig *SqlActiveDirectoryConfig `json:"activeDirectoryConfig,omitempty"`// AdvancedMachineFeatures: Specifies advanced machine configuration for the// instances relevant only for SQL Server.AdvancedMachineFeatures *AdvancedMachineFeatures `json:"advancedMachineFeatures,omitempty"`// AuthorizedGaeApplications: The App Engine app IDs that can access this// instance. (Deprecated) Applied to First Generation instances only.AuthorizedGaeApplications []string `json:"authorizedGaeApplications,omitempty"`// AutoUpgradeEnabled: Optional. Cloud SQL for MySQL auto-upgrade// configuration. When this parameter is set to true, auto-upgrade is enabled// for MySQL 8.0 minor versions. The MySQL version must be 8.0.35 or higher.AutoUpgradeEnabledbool `json:"autoUpgradeEnabled,omitempty"`// AvailabilityType: Availability type. Potential values: * `ZONAL`: The// instance serves data from only one zone. Outages in that zone affect data// accessibility. * `REGIONAL`: The instance can serve data from more than one// zone in a region (it is highly available)./ For more information, see// Overview of the High Availability Configuration// (https://cloud.google.com/sql/docs/mysql/high-availability).//// Possible values:// "SQL_AVAILABILITY_TYPE_UNSPECIFIED" - This is an unknown Availability// type.// "ZONAL" - Zonal available instance.// "REGIONAL" - Regional available instance.AvailabilityTypestring `json:"availabilityType,omitempty"`// BackupConfiguration: The daily backup configuration for the instance.BackupConfiguration *BackupConfiguration `json:"backupConfiguration,omitempty"`// Collation: The name of server Instance collation.Collationstring `json:"collation,omitempty"`// ConnectionPoolConfig: Optional. The managed connection pooling configuration// for the instance.ConnectionPoolConfig *ConnectionPoolConfig `json:"connectionPoolConfig,omitempty"`// ConnectorEnforcement: Specifies if connections must use Cloud SQL// connectors. Option values include the following: `NOT_REQUIRED` (Cloud SQL// instances can be connected without Cloud SQL Connectors) and `REQUIRED`// (Only allow connections that use Cloud SQL Connectors). Note that using// REQUIRED disables all existing authorized networks. If this field is not// specified when creating a new instance, NOT_REQUIRED is used. If this field// is not specified when patching or updating an existing instance, it is left// unchanged in the instance.//// Possible values:// "CONNECTOR_ENFORCEMENT_UNSPECIFIED" - The requirement for Cloud SQL// connectors is unknown.// "NOT_REQUIRED" - Do not require Cloud SQL connectors.// "REQUIRED" - Require all connections to use Cloud SQL connectors,// including the Cloud SQL Auth Proxy and Cloud SQL Java, Python, and Go// connectors. Note: This disables all existing authorized networks.ConnectorEnforcementstring `json:"connectorEnforcement,omitempty"`// CrashSafeReplicationEnabled: Configuration specific to read replica// instances. Indicates whether database flags for crash-safe replication are// enabled. This property was only applicable to First Generation instances.CrashSafeReplicationEnabledbool `json:"crashSafeReplicationEnabled,omitempty"`// DataApiAccess: This parameter controls whether to allow using ExecuteSql API// to connect to the instance. Not allowed by default.//// Possible values:// "DATA_API_ACCESS_UNSPECIFIED" - Unspecified, effectively the same as// `DISALLOW_DATA_API`.// "DISALLOW_DATA_API" - Disallow using ExecuteSql API to connect to the// instance.// "ALLOW_DATA_API" - Allow using ExecuteSql API to connect to the instance.// For private IP instances, this allows authorized users to access the// instance from the public internet using ExecuteSql API.DataApiAccessstring `json:"dataApiAccess,omitempty"`// DataCacheConfig: Configuration for data cache.DataCacheConfig *DataCacheConfig `json:"dataCacheConfig,omitempty"`// DataDiskProvisionedIops: Optional. Provisioned number of I/O operations per// second for the data disk. This field is only used for hyperdisk-balanced// disk types.DataDiskProvisionedIopsint64 `json:"dataDiskProvisionedIops,omitempty,string"`// DataDiskProvisionedThroughput: Optional. Provisioned throughput measured in// MiB per second for the data disk. This field is only used for// hyperdisk-balanced disk types.DataDiskProvisionedThroughputint64 `json:"dataDiskProvisionedThroughput,omitempty,string"`// DataDiskSizeGb: The size of data disk, in GB. The data disk size minimum is// 10GB.DataDiskSizeGbint64 `json:"dataDiskSizeGb,omitempty,string"`// DataDiskType: The type of data disk: `PD_SSD` (default) or `PD_HDD`. Not// used for First Generation instances.//// Possible values:// "SQL_DATA_DISK_TYPE_UNSPECIFIED" - This is an unknown data disk type.// "PD_SSD" - An SSD data disk.// "PD_HDD" - An HDD data disk.// "OBSOLETE_LOCAL_SSD" - This field is deprecated and will be removed from a// future version of the API.// "HYPERDISK_BALANCED" - A Hyperdisk Balanced data disk.DataDiskTypestring `json:"dataDiskType,omitempty"`// DatabaseFlags: The database flags passed to the instance at startup.DatabaseFlags []*DatabaseFlags `json:"databaseFlags,omitempty"`// DatabaseReplicationEnabled: Configuration specific to read replica// instances. Indicates whether replication is enabled or not. WARNING:// Changing this restarts the instance.DatabaseReplicationEnabledbool `json:"databaseReplicationEnabled,omitempty"`// DeletionProtectionEnabled: Configuration to protect against accidental// instance deletion.DeletionProtectionEnabledbool `json:"deletionProtectionEnabled,omitempty"`// DenyMaintenancePeriods: Deny maintenance periodsDenyMaintenancePeriods []*DenyMaintenancePeriod `json:"denyMaintenancePeriods,omitempty"`// Edition: Optional. The edition of the instance.//// Possible values:// "EDITION_UNSPECIFIED" - The instance did not specify the edition.// "ENTERPRISE" - The instance is an enterprise edition.// "ENTERPRISE_PLUS" - The instance is an Enterprise Plus edition.Editionstring `json:"edition,omitempty"`// EnableDataplexIntegration: Optional. By default, Cloud SQL instances have// schema extraction disabled for Dataplex. When this parameter is set to true,// schema extraction for Dataplex on Cloud SQL instances is activated.EnableDataplexIntegrationbool `json:"enableDataplexIntegration,omitempty"`// EnableGoogleMlIntegration: Optional. When this parameter is set to true,// Cloud SQL instances can connect to Vertex AI to pass requests for real-time// predictions and insights to the AI. The default value is false. This applies// only to Cloud SQL for MySQL and Cloud SQL for PostgreSQL instances.EnableGoogleMlIntegrationbool `json:"enableGoogleMlIntegration,omitempty"`// EntraidConfig: Optional. The Microsoft Entra ID configuration for the SQL// Server instance.EntraidConfig *SqlServerEntraIdConfig `json:"entraidConfig,omitempty"`// FinalBackupConfig: Optional. The final backup configuration for the// instance.FinalBackupConfig *FinalBackupConfig `json:"finalBackupConfig,omitempty"`// InsightsConfig: Insights configuration, for now relevant only for Postgres.InsightsConfig *InsightsConfig `json:"insightsConfig,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. The IPv4 address cannot be disabled for Second Generation// instances.IpConfiguration *IpConfiguration `json:"ipConfiguration,omitempty"`// Kind: This is always `sql#settings`.Kindstring `json:"kind,omitempty"`// LocationPreference: The location preference settings. This allows the// instance to be located as near as possible to either an App Engine app or// Compute Engine zone for better performance. App Engine co-location was only// applicable to First Generation instances.LocationPreference *LocationPreference `json:"locationPreference,omitempty"`// MaintenanceWindow: The maintenance window for this instance. This specifies// when the instance can be restarted for maintenance purposes.MaintenanceWindow *MaintenanceWindow `json:"maintenanceWindow,omitempty"`// PasswordValidationPolicy: The local user password validation policy of the// instance.PasswordValidationPolicy *PasswordValidationPolicy `json:"passwordValidationPolicy,omitempty"`// PricingPlan: The pricing plan for this instance. This can be either// `PER_USE` or `PACKAGE`. Only `PER_USE` is supported for Second Generation// instances.//// Possible values:// "SQL_PRICING_PLAN_UNSPECIFIED" - This is an unknown pricing plan for this// instance.// "PACKAGE" - The instance is billed at a monthly flat rate.// "PER_USE" - The instance is billed per usage.PricingPlanstring `json:"pricingPlan,omitempty"`// ReadPoolAutoScaleConfig: Optional. The read pool auto-scale configuration// for the instance.ReadPoolAutoScaleConfig *ReadPoolAutoScaleConfig `json:"readPoolAutoScaleConfig,omitempty"`// ReplicationLagMaxSeconds: Optional. Configuration value for recreation of// replica after certain replication lagReplicationLagMaxSecondsint64 `json:"replicationLagMaxSeconds,omitempty"`// ReplicationType: The type of replication this instance uses. This can be// either `ASYNCHRONOUS` or `SYNCHRONOUS`. (Deprecated) This property was only// applicable to First Generation instances.//// Possible values:// "SQL_REPLICATION_TYPE_UNSPECIFIED" - This is an unknown replication type// for a Cloud SQL instance.// "SYNCHRONOUS" - The synchronous replication mode for First Generation// instances. It is the default value.// "ASYNCHRONOUS" - The asynchronous replication mode for First Generation// instances. It provides a slight performance gain, but if an outage occurs// while this option is set to asynchronous, you can lose up to a few seconds// of updates to your data.ReplicationTypestring `json:"replicationType,omitempty"`// RetainBackupsOnDelete: Optional. When this parameter is set to true, Cloud// SQL retains backups of the instance even after the instance is deleted. The// ON_DEMAND backup will be retained until customer deletes the backup or the// project. The AUTOMATED backup will be retained based on the backups// retention setting.RetainBackupsOnDeletebool `json:"retainBackupsOnDelete,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.SettingsVersionint64 `json:"settingsVersion,omitempty,string"`// SqlServerAuditConfig: SQL Server specific audit configuration.SqlServerAuditConfig *SqlServerAuditConfig `json:"sqlServerAuditConfig,omitempty"`// StorageAutoResize: Configuration to increase storage size automatically. The// default value is true.StorageAutoResize *bool `json:"storageAutoResize,omitempty"`// StorageAutoResizeLimit: The maximum size to which storage capacity can be// automatically increased. The default value is 0, which specifies that there// is no limit.StorageAutoResizeLimitint64 `json:"storageAutoResizeLimit,omitempty,string"`// Tier: The tier (or machine type) for this instance, for example// `db-custom-1-3840`. WARNING: Changing this restarts the instance.Tierstring `json:"tier,omitempty"`// TimeZone: Server timezone, relevant only for Cloud SQL for SQL Server.TimeZonestring `json:"timeZone,omitempty"`// UserLabels: User-provided labels, represented as a dictionary where each// label is a single key value pair.UserLabels map[string]string `json:"userLabels,omitempty"`// ForceSendFields is a list of field names (e.g. "ActivationPolicy") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ActivationPolicy") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Settings: Database instance settings.
func (Settings)MarshalJSON¶
typeSqlActiveDirectoryConfig¶
type SqlActiveDirectoryConfig struct {// AdminCredentialSecretName: Optional. The secret manager key storing the// administrator credential. (e.g., projects/{project}/secrets/{secret}).AdminCredentialSecretNamestring `json:"adminCredentialSecretName,omitempty"`// DnsServers: Optional. Domain controller IPv4 addresses used to bootstrap// Active Directory.DnsServers []string `json:"dnsServers,omitempty"`// Domain: The name of the domain (e.g., mydomain.com).Domainstring `json:"domain,omitempty"`// Kind: This is always sql#activeDirectoryConfig.Kindstring `json:"kind,omitempty"`// Mode: Optional. The mode of the Active Directory configuration.//// Possible values:// "ACTIVE_DIRECTORY_MODE_UNSPECIFIED" - Unspecified mode. Will default to// MANAGED_ACTIVE_DIRECTORY if the mode is not specified to maintain backward// compatibility.// "MANAGED_ACTIVE_DIRECTORY" - Managed Active Directory mode.// "SELF_MANAGED_ACTIVE_DIRECTORY" - Deprecated: Use// CUSTOMER_MANAGED_ACTIVE_DIRECTORY instead.// "CUSTOMER_MANAGED_ACTIVE_DIRECTORY" - Customer-managed Active Directory// mode.Modestring `json:"mode,omitempty"`// OrganizationalUnit: Optional. The organizational unit distinguished name.// This is the full hierarchical path to the organizational unit.OrganizationalUnitstring `json:"organizationalUnit,omitempty"`// ForceSendFields is a list of field names (e.g. "AdminCredentialSecretName")// to unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AdminCredentialSecretName") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlActiveDirectoryConfig: Active Directory configuration, relevant only forCloud SQL for SQL Server.
func (SqlActiveDirectoryConfig)MarshalJSON¶
func (sSqlActiveDirectoryConfig) MarshalJSON() ([]byte,error)
typeSqlExternalSyncSettingError¶added inv0.52.0
type SqlExternalSyncSettingError struct {// Detail: Additional information about the error encountered.Detailstring `json:"detail,omitempty"`// Kind: Can be `sql#externalSyncSettingError` or// `sql#externalSyncSettingWarning`.Kindstring `json:"kind,omitempty"`// Type: Identifies the specific error that occurred.//// Possible values:// "SQL_EXTERNAL_SYNC_SETTING_ERROR_TYPE_UNSPECIFIED"// "CONNECTION_FAILURE"// "BINLOG_NOT_ENABLED"// "INCOMPATIBLE_DATABASE_VERSION"// "REPLICA_ALREADY_SETUP"// "INSUFFICIENT_PRIVILEGE" - The replication user is missing privileges that// are required.// "UNSUPPORTED_MIGRATION_TYPE" - Unsupported migration type.// "NO_PGLOGICAL_INSTALLED" - No pglogical extension installed on databases,// applicable for postgres.// "PGLOGICAL_NODE_ALREADY_EXISTS" - pglogical node already exists on// databases, applicable for postgres.// "INVALID_WAL_LEVEL" - The value of parameter wal_level is not set to// logical.// "INVALID_SHARED_PRELOAD_LIBRARY" - The value of parameter// shared_preload_libraries does not include pglogical.// "INSUFFICIENT_MAX_REPLICATION_SLOTS" - The value of parameter// max_replication_slots is not sufficient.// "INSUFFICIENT_MAX_WAL_SENDERS" - The value of parameter max_wal_senders is// not sufficient.// "INSUFFICIENT_MAX_WORKER_PROCESSES" - The value of parameter// max_worker_processes is not sufficient.// "UNSUPPORTED_EXTENSIONS" - Extensions installed are either not supported// or having unsupported versions.// "INVALID_RDS_LOGICAL_REPLICATION" - The value of parameter// rds.logical_replication is not set to 1.// "INVALID_LOGGING_SETUP" - The primary instance logging setup doesn't allow// EM sync.// "INVALID_DB_PARAM" - The primary instance database parameter setup doesn't// allow EM sync.// "UNSUPPORTED_GTID_MODE" - The gtid_mode is not supported, applicable for// MySQL.// "SQLSERVER_AGENT_NOT_RUNNING" - SQL Server Agent is not running.// "UNSUPPORTED_TABLE_DEFINITION" - The table definition is not support due// to missing primary key or replica identity, applicable for postgres. Note// that this is a warning and won't block the migration.// "UNSUPPORTED_DEFINER" - The customer has a definer that will break EM// setup.// "SQLSERVER_SERVERNAME_MISMATCH" - SQL Server @@SERVERNAME does not match// actual host name.// "PRIMARY_ALREADY_SETUP" - The primary instance has been setup and will// fail the setup.// "UNSUPPORTED_BINLOG_FORMAT" - The primary instance has unsupported binary// log format.// "BINLOG_RETENTION_SETTING" - The primary instance's binary log retention// setting.// "UNSUPPORTED_STORAGE_ENGINE" - The primary instance has tables with// unsupported storage engine.// "LIMITED_SUPPORT_TABLES" - Source has tables with limited support eg:// PostgreSQL tables without primary keys.// "EXISTING_DATA_IN_REPLICA" - The replica instance contains existing data.// "MISSING_OPTIONAL_PRIVILEGES" - The replication user is missing privileges// that are optional.// "RISKY_BACKUP_ADMIN_PRIVILEGE" - Additional BACKUP_ADMIN privilege is// granted to the replication user which may lock source MySQL 8 instance for// DDLs during initial sync.// "INSUFFICIENT_GCS_PERMISSIONS" - The Cloud Storage bucket is missing// necessary permissions.// "INVALID_FILE_INFO" - The Cloud Storage bucket has an error in the file or// contains invalid file information.// "UNSUPPORTED_DATABASE_SETTINGS" - The source instance has unsupported// database settings for migration.// "MYSQL_PARALLEL_IMPORT_INSUFFICIENT_PRIVILEGE" - The replication user is// missing parallel import specific privileges. (e.g. LOCK TABLES) for MySQL.// "LOCAL_INFILE_OFF" - The global variable local_infile is off on external// server replica.// "TURN_ON_PITR_AFTER_PROMOTE" - This code instructs customers to turn on// point-in-time recovery manually for the instance after promoting the Cloud// SQL for PostgreSQL instance.// "INCOMPATIBLE_DATABASE_MINOR_VERSION" - The minor version of replica// database is incompatible with the source.// "SOURCE_MAX_SUBSCRIPTIONS" - This warning message indicates that Cloud SQL// uses the maximum number of subscriptions to migrate data from the source to// the destination.// "UNABLE_TO_VERIFY_DEFINERS" - Unable to verify definers on the source for// MySQL.// "SUBSCRIPTION_CALCULATION_STATUS" - If a time out occurs while the// subscription counts are calculated, then this value is set to 1. Otherwise,// this value is set to 2.// "PG_SUBSCRIPTION_COUNT" - Count of subscriptions needed to sync source// data for PostgreSQL database.// "PG_SYNC_PARALLEL_LEVEL" - Final parallel level that is used to do// migration.// "INSUFFICIENT_DISK_SIZE" - The disk size of the replica instance is// smaller than the data size of the source instance.// "INSUFFICIENT_MACHINE_TIER" - The data size of the source instance is// greater than 1 TB, the number of cores of the replica instance is less than// 8, and the memory of the replica is less than 32 GB.// "UNSUPPORTED_EXTENSIONS_NOT_MIGRATED" - The warning message indicates the// unsupported extensions will not be migrated to the destination.// "EXTENSIONS_NOT_MIGRATED" - The warning message indicates the pg_cron// extension and settings will not be migrated to the destination.// "PG_CRON_FLAG_ENABLED_IN_REPLICA" - The error message indicates that// pg_cron flags are enabled on the destination which is not supported during// the migration.// "EXTENSIONS_NOT_ENABLED_IN_REPLICA" - This error message indicates that// the specified extensions are not enabled on destination instance. For// example, before you can migrate data to the destination instance, you must// enable the PGAudit extension on the instance.// "UNSUPPORTED_COLUMNS" - The source database has generated columns that// can't be migrated. Please change them to regular columns before migration.// "USERS_NOT_CREATED_IN_REPLICA" - The source database has users that aren't// created in the replica. First, create all users, which are in the// pg_user_mappings table of the source database, in the destination instance.// Then, perform the migration.// "UNSUPPORTED_SYSTEM_OBJECTS" - The selected objects include system objects// that aren't supported for migration.// "UNSUPPORTED_TABLES_WITH_REPLICA_IDENTITY" - The source database has// tables with the FULL or NOTHING replica identity. Before starting your// migration, either remove the identity or change it to DEFAULT. Note that// this is an error and will block the migration.// "SELECTED_OBJECTS_NOT_EXIST_ON_SOURCE" - The selected objects don't exist// on the source instance.// "PSC_ONLY_INSTANCE_WITH_NO_NETWORK_ATTACHMENT_URI" - PSC only destination// instance does not have a network attachment URI.// "SELECTED_OBJECTS_REFERENCE_UNSELECTED_OBJECTS" - Selected objects// reference unselected objects. Based on their object type (foreign key// constraint or view), selected objects will fail during migration.// "PROMPT_DELETE_EXISTING" - The migration will delete existing data in the// replica; set replica_overwrite_enabled in the request to acknowledge this.// This is an error. MySQL only.// "WILL_DELETE_EXISTING" - The migration will delete existing data in the// replica; replica_overwrite_enabled was set in the request acknowledging// this. This is a warning rather than an error. MySQL only.// "PG_DDL_REPLICATION_INSUFFICIENT_PRIVILEGE" - The replication user is// missing specific privileges to setup DDL replication. (e.g. CREATE EVENT// TRIGGER, CREATE SCHEMA) for PostgreSQL.Typestring `json:"type,omitempty"`// ForceSendFields is a list of field names (e.g. "Detail") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Detail") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlExternalSyncSettingError: External primary instance migration settingerror/warning.
func (SqlExternalSyncSettingError)MarshalJSON¶added inv0.52.0
func (sSqlExternalSyncSettingError) MarshalJSON() ([]byte,error)
typeSqlInstancesAcquireSsrsLeaseResponse¶added inv0.170.0
type SqlInstancesAcquireSsrsLeaseResponse struct {// OperationId: The unique identifier for this operation.OperationIdstring `json:"operationId,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "OperationId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "OperationId") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesAcquireSsrsLeaseResponse: Response for the acquire SSRS leaserequest.
func (SqlInstancesAcquireSsrsLeaseResponse)MarshalJSON¶added inv0.170.0
func (sSqlInstancesAcquireSsrsLeaseResponse) MarshalJSON() ([]byte,error)
typeSqlInstancesExecuteSqlResponse¶added inv0.248.0
type SqlInstancesExecuteSqlResponse struct {// Messages: A list of notices and warnings generated during query execution.// For PostgreSQL, this includes all notices and warnings. For MySQL, this// includes warnings generated by the last executed statement. To retrieve all// warnings for a multi-statement query, `SHOW WARNINGS` must be executed after// each statement.Messages []*Message `json:"messages,omitempty"`// Metadata: The additional metadata information regarding the execution of the// SQL statements.Metadata *Metadata `json:"metadata,omitempty"`// Results: The list of results after executing all the SQL statements.Results []*QueryResult `json:"results,omitempty"`// Status: Contains the error from the database if the SQL execution failed.Status *Status `json:"status,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Messages") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Messages") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesExecuteSqlResponse: Execute SQL statements response.
func (SqlInstancesExecuteSqlResponse)MarshalJSON¶added inv0.248.0
func (sSqlInstancesExecuteSqlResponse) MarshalJSON() ([]byte,error)
typeSqlInstancesGetDiskShrinkConfigResponse¶added inv0.114.0
type SqlInstancesGetDiskShrinkConfigResponse struct {// Kind: This is always `sql#getDiskShrinkConfig`.Kindstring `json:"kind,omitempty"`// Message: Additional message to customers.Messagestring `json:"message,omitempty"`// MinimalTargetSizeGb: The minimum size to which a disk can be shrunk in// GigaBytes.MinimalTargetSizeGbint64 `json:"minimalTargetSizeGb,omitempty,string"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesGetDiskShrinkConfigResponse: Instance get disk shrink configresponse.
func (SqlInstancesGetDiskShrinkConfigResponse)MarshalJSON¶added inv0.114.0
func (sSqlInstancesGetDiskShrinkConfigResponse) MarshalJSON() ([]byte,error)
typeSqlInstancesGetLatestRecoveryTimeResponse¶added inv0.130.0
type SqlInstancesGetLatestRecoveryTimeResponse struct {// EarliestRecoveryTime: Timestamp, identifies the earliest recovery time of// the source instance.EarliestRecoveryTimestring `json:"earliestRecoveryTime,omitempty"`// Kind: This is always `sql#getLatestRecoveryTime`.Kindstring `json:"kind,omitempty"`// LatestRecoveryTime: Timestamp, identifies the latest recovery time of the// source instance.LatestRecoveryTimestring `json:"latestRecoveryTime,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "EarliestRecoveryTime") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "EarliestRecoveryTime") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesGetLatestRecoveryTimeResponse: Instance get latest recovery timeresponse.
func (SqlInstancesGetLatestRecoveryTimeResponse)MarshalJSON¶added inv0.130.0
func (sSqlInstancesGetLatestRecoveryTimeResponse) MarshalJSON() ([]byte,error)
typeSqlInstancesReleaseSsrsLeaseResponse¶added inv0.170.0
type SqlInstancesReleaseSsrsLeaseResponse struct {// OperationId: The unique identifier for this operation.OperationIdstring `json:"operationId,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "OperationId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "OperationId") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesReleaseSsrsLeaseResponse: Response for the release SSRS leaserequest.
func (SqlInstancesReleaseSsrsLeaseResponse)MarshalJSON¶added inv0.170.0
func (sSqlInstancesReleaseSsrsLeaseResponse) MarshalJSON() ([]byte,error)
typeSqlInstancesRescheduleMaintenanceRequestBody¶added inv0.52.0
type SqlInstancesRescheduleMaintenanceRequestBody struct {// Reschedule: Required. The type of the reschedule the user wants.Reschedule *Reschedule `json:"reschedule,omitempty"`// ForceSendFields is a list of field names (e.g. "Reschedule") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Reschedule") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesRescheduleMaintenanceRequestBody: Reschedule options formaintenance windows.
func (SqlInstancesRescheduleMaintenanceRequestBody)MarshalJSON¶added inv0.52.0
func (sSqlInstancesRescheduleMaintenanceRequestBody) MarshalJSON() ([]byte,error)
typeSqlInstancesResetReplicaSizeRequest¶added inv0.114.0
type SqlInstancesResetReplicaSizeRequest struct {}SqlInstancesResetReplicaSizeRequest: Instance reset replica size request.
typeSqlInstancesStartExternalSyncRequest¶added inv0.53.0
type SqlInstancesStartExternalSyncRequest struct {// MigrationType: Optional. MigrationType configures the migration to use// physical files or logical dump files. If not set, then the logical dump file// configuration is used. Valid values are `LOGICAL` or `PHYSICAL`. Only// applicable to MySQL.//// Possible values:// "MIGRATION_TYPE_UNSPECIFIED" - Default value is a logical dump file-based// migration// "LOGICAL" - Logical dump file-based migration// "PHYSICAL" - Physical file-based migrationMigrationTypestring `json:"migrationType,omitempty"`// MysqlSyncConfig: MySQL-specific settings for start external sync.MysqlSyncConfig *MySqlSyncConfig `json:"mysqlSyncConfig,omitempty"`// ReplicaOverwriteEnabled: Optional. MySQL only. True if end-user has// confirmed that this SES call will wipe replica databases overlapping with// the proposed selected_objects. If this field is not set and there are both// overlapping and additional databases proposed, an error will be returned.ReplicaOverwriteEnabledbool `json:"replicaOverwriteEnabled,omitempty"`// SkipVerification: Whether to skip the verification step (VESS).SkipVerificationbool `json:"skipVerification,omitempty"`// SyncMode: External sync mode.//// Possible values:// "EXTERNAL_SYNC_MODE_UNSPECIFIED" - Unknown external sync mode, will be// defaulted to ONLINE mode// "ONLINE" - Online external sync will set up replication after initial data// external sync// "OFFLINE" - Offline external sync only dumps and loads a one-time snapshot// of the primary instance's dataSyncModestring `json:"syncMode,omitempty"`// SyncParallelLevel: Optional. Parallel level for initial data sync. Currently// only applicable for MySQL.//// Possible values:// "EXTERNAL_SYNC_PARALLEL_LEVEL_UNSPECIFIED" - Unknown sync parallel level.// Will be defaulted to OPTIMAL.// "MIN" - Minimal parallel level.// "OPTIMAL" - Optimal parallel level.// "MAX" - Maximum parallel level.SyncParallelLevelstring `json:"syncParallelLevel,omitempty"`// ForceSendFields is a list of field names (e.g. "MigrationType") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MigrationType") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesStartExternalSyncRequest: Instance start external sync request.
func (SqlInstancesStartExternalSyncRequest)MarshalJSON¶added inv0.53.0
func (sSqlInstancesStartExternalSyncRequest) MarshalJSON() ([]byte,error)
typeSqlInstancesVerifyExternalSyncSettingsRequest¶added inv0.53.0
type SqlInstancesVerifyExternalSyncSettingsRequest struct {// MigrationType: Optional. MigrationType configures the migration to use// physical files or logical dump files. If not set, then the logical dump file// configuration is used. Valid values are `LOGICAL` or `PHYSICAL`. Only// applicable to MySQL.//// Possible values:// "MIGRATION_TYPE_UNSPECIFIED" - Default value is a logical dump file-based// migration// "LOGICAL" - Logical dump file-based migration// "PHYSICAL" - Physical file-based migrationMigrationTypestring `json:"migrationType,omitempty"`// MysqlSyncConfig: Optional. MySQL-specific settings for start external sync.MysqlSyncConfig *MySqlSyncConfig `json:"mysqlSyncConfig,omitempty"`// SelectedObjects: Optional. Migrate only the specified objects from the// source instance. If this field is empty, then migrate all objects.SelectedObjects []*ExternalSyncSelectedObject `json:"selectedObjects,omitempty"`// SyncMode: External sync mode//// Possible values:// "EXTERNAL_SYNC_MODE_UNSPECIFIED" - Unknown external sync mode, will be// defaulted to ONLINE mode// "ONLINE" - Online external sync will set up replication after initial data// external sync// "OFFLINE" - Offline external sync only dumps and loads a one-time snapshot// of the primary instance's dataSyncModestring `json:"syncMode,omitempty"`// SyncParallelLevel: Optional. Parallel level for initial data sync. Only// applicable for PostgreSQL.//// Possible values:// "EXTERNAL_SYNC_PARALLEL_LEVEL_UNSPECIFIED" - Unknown sync parallel level.// Will be defaulted to OPTIMAL.// "MIN" - Minimal parallel level.// "OPTIMAL" - Optimal parallel level.// "MAX" - Maximum parallel level.SyncParallelLevelstring `json:"syncParallelLevel,omitempty"`// VerifyConnectionOnly: Flag to enable verifying connection onlyVerifyConnectionOnlybool `json:"verifyConnectionOnly,omitempty"`// VerifyReplicationOnly: Optional. Flag to verify settings required by// replication setup onlyVerifyReplicationOnlybool `json:"verifyReplicationOnly,omitempty"`// ForceSendFields is a list of field names (e.g. "MigrationType") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MigrationType") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesVerifyExternalSyncSettingsRequest: Instance verify external syncsettings request.
func (SqlInstancesVerifyExternalSyncSettingsRequest)MarshalJSON¶added inv0.53.0
func (sSqlInstancesVerifyExternalSyncSettingsRequest) MarshalJSON() ([]byte,error)
typeSqlInstancesVerifyExternalSyncSettingsResponse¶added inv0.52.0
type SqlInstancesVerifyExternalSyncSettingsResponse struct {// Errors: List of migration violations.Errors []*SqlExternalSyncSettingError `json:"errors,omitempty"`// Kind: This is always `sql#migrationSettingErrorList`.Kindstring `json:"kind,omitempty"`// Warnings: List of migration warnings.Warnings []*SqlExternalSyncSettingError `json:"warnings,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Errors") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Errors") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlInstancesVerifyExternalSyncSettingsResponse: Instance verify externalsync settings response.
func (SqlInstancesVerifyExternalSyncSettingsResponse)MarshalJSON¶added inv0.52.0
func (sSqlInstancesVerifyExternalSyncSettingsResponse) MarshalJSON() ([]byte,error)
typeSqlOutOfDiskReport¶
type SqlOutOfDiskReport struct {// SqlMinRecommendedIncreaseSizeGb: The minimum recommended increase size in// GigaBytes This field is consumed by the frontend * Writers: * the proactive// database wellness job for OOD. * Readers:SqlMinRecommendedIncreaseSizeGbint64 `json:"sqlMinRecommendedIncreaseSizeGb,omitempty"`// SqlOutOfDiskState: This field represents the state generated by the// proactive database wellness job for OutOfDisk issues. * Writers: * the// proactive database wellness job for OOD. * Readers: * the proactive database// wellness job//// Possible values:// "SQL_OUT_OF_DISK_STATE_UNSPECIFIED" - Unspecified state// "NORMAL" - The instance has plenty space on data disk// "SOFT_SHUTDOWN" - Data disk is almost used up. It is shutdown to prevent// data corruption.SqlOutOfDiskStatestring `json:"sqlOutOfDiskState,omitempty"`// ForceSendFields is a list of field names (e.g.// "SqlMinRecommendedIncreaseSizeGb") to unconditionally include in API// requests. By default, fields with empty or default values are omitted from// API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "SqlMinRecommendedIncreaseSizeGb")// to include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlOutOfDiskReport: This message wraps up the information written byout-of-disk detection job.
func (SqlOutOfDiskReport)MarshalJSON¶
func (sSqlOutOfDiskReport) MarshalJSON() ([]byte,error)
typeSqlScheduledMaintenance¶
type SqlScheduledMaintenance struct {CanDeferbool `json:"canDefer,omitempty"`// CanReschedule: If the scheduled maintenance can be rescheduled.CanReschedulebool `json:"canReschedule,omitempty"`// ScheduleDeadlineTime: Maintenance cannot be rescheduled to start beyond this// deadline.ScheduleDeadlineTimestring `json:"scheduleDeadlineTime,omitempty"`// StartTime: The start time of any upcoming scheduled maintenance for this// instance.StartTimestring `json:"startTime,omitempty"`// ForceSendFields is a list of field names (e.g. "CanDefer") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CanDefer") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlScheduledMaintenance: Any scheduled maintenance for this instance.
func (SqlScheduledMaintenance)MarshalJSON¶
func (sSqlScheduledMaintenance) MarshalJSON() ([]byte,error)
typeSqlServerAuditConfig¶added inv0.57.0
type SqlServerAuditConfig struct {// Bucket: The name of the destination bucket (e.g., gs://mybucket).Bucketstring `json:"bucket,omitempty"`// Kind: This is always sql#sqlServerAuditConfigKindstring `json:"kind,omitempty"`// RetentionInterval: How long to keep generated audit files.RetentionIntervalstring `json:"retentionInterval,omitempty"`// UploadInterval: How often to upload generated audit files.UploadIntervalstring `json:"uploadInterval,omitempty"`// ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Bucket") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlServerAuditConfig: SQL Server specific audit configuration.
func (SqlServerAuditConfig)MarshalJSON¶added inv0.57.0
func (sSqlServerAuditConfig) MarshalJSON() ([]byte,error)
typeSqlServerDatabaseDetails¶added inv0.52.0
type SqlServerDatabaseDetails struct {// CompatibilityLevel: The version of SQL Server with which the database is to// be made compatibleCompatibilityLevelint64 `json:"compatibilityLevel,omitempty"`// RecoveryModel: The recovery model of a SQL Server databaseRecoveryModelstring `json:"recoveryModel,omitempty"`// ForceSendFields is a list of field names (e.g. "CompatibilityLevel") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CompatibilityLevel") to include// in API requests with the JSON null value. By default, fields with empty// values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlServerDatabaseDetails: Represents a Sql Server database on the Cloud SQLinstance.
func (SqlServerDatabaseDetails)MarshalJSON¶added inv0.52.0
func (sSqlServerDatabaseDetails) MarshalJSON() ([]byte,error)
typeSqlServerEntraIdConfig¶added inv0.257.0
type SqlServerEntraIdConfig struct {// ApplicationId: Optional. The application ID for the Entra ID configuration.ApplicationIdstring `json:"applicationId,omitempty"`// Kind: Output only. This is always sql#sqlServerEntraIdConfigKindstring `json:"kind,omitempty"`// TenantId: Optional. The tenant ID for the Entra ID configuration.TenantIdstring `json:"tenantId,omitempty"`// ForceSendFields is a list of field names (e.g. "ApplicationId") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ApplicationId") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlServerEntraIdConfig: SQL Server Entra ID configuration.
func (SqlServerEntraIdConfig)MarshalJSON¶added inv0.257.0
func (sSqlServerEntraIdConfig) MarshalJSON() ([]byte,error)
typeSqlServerUserDetails¶added inv0.52.0
type SqlServerUserDetails struct {// Disabled: If the user has been disabledDisabledbool `json:"disabled,omitempty"`// ServerRoles: The server roles for this userServerRoles []string `json:"serverRoles,omitempty"`// ForceSendFields is a list of field names (e.g. "Disabled") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Disabled") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlServerUserDetails: Represents a Sql Server user on the Cloud SQLinstance.
func (SqlServerUserDetails)MarshalJSON¶added inv0.52.0
func (sSqlServerUserDetails) MarshalJSON() ([]byte,error)
typeSqlSubOperationType¶added inv0.212.0
type SqlSubOperationType struct {// MaintenanceType: The type of maintenance to be performed on the instance.//// Possible values:// "SQL_MAINTENANCE_TYPE_UNSPECIFIED" - Maintenance type is unspecified.// "INSTANCE_MAINTENANCE" - Indicates that a standalone instance is// undergoing maintenance. The instance can be either a primary instance or a// replica.// "REPLICA_INCLUDED_MAINTENANCE" - Indicates that the primary instance and// all of its replicas, including cascading replicas, are undergoing// maintenance. Maintenance is performed on groups of replicas first, followed// by the primary instance.// "INSTANCE_SELF_SERVICE_MAINTENANCE" - Indicates that the standalone// instance is undergoing maintenance, initiated by self-service. The instance// can be either a primary instance or a replica.// "REPLICA_INCLUDED_SELF_SERVICE_MAINTENANCE" - Indicates that the primary// instance and all of its replicas are undergoing maintenance, initiated by// self-service. Maintenance is performed on groups of replicas first, followed// by the primary instance.MaintenanceTypestring `json:"maintenanceType,omitempty"`// ForceSendFields is a list of field names (e.g. "MaintenanceType") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "MaintenanceType") to include in// API requests with the JSON null value. By default, fields with empty values// are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SqlSubOperationType: The sub operation type based on the operation type.
func (SqlSubOperationType)MarshalJSON¶added inv0.212.0
func (sSqlSubOperationType) MarshalJSON() ([]byte,error)
typeSslCert¶
type SslCert struct {// Cert: PEM representation.Certstring `json:"cert,omitempty"`// CertSerialNumber: Serial number, as extracted from the certificate.CertSerialNumberstring `json:"certSerialNumber,omitempty"`// CommonName: User supplied name. Constrained to [a-zA-Z.-_ ]+.CommonNamestring `json:"commonName,omitempty"`// CreateTime: The time when the certificate was created inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`CreateTimestring `json:"createTime,omitempty"`// ExpirationTime: The time when the certificate expires inRFC 3339// (https://tools.ietf.org/html/rfc3339) format, for example// `2012-11-15T16:19:00.094Z`.ExpirationTimestring `json:"expirationTime,omitempty"`// Instance: Name of the database instance.Instancestring `json:"instance,omitempty"`// Kind: This is always `sql#sslCert`.Kindstring `json:"kind,omitempty"`// SelfLink: The URI of this resource.SelfLinkstring `json:"selfLink,omitempty"`// Sha1Fingerprint: Sha1 Fingerprint.Sha1Fingerprintstring `json:"sha1Fingerprint,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Cert") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Cert") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SslCert: SslCerts Resource
func (SslCert)MarshalJSON¶
typeSslCertDetail¶added inv0.52.0
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.CertPrivateKeystring `json:"certPrivateKey,omitempty"`// ForceSendFields is a list of field names (e.g. "CertInfo") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CertInfo") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SslCertDetail: SslCertDetail.
func (SslCertDetail)MarshalJSON¶added inv0.52.0
func (sSslCertDetail) MarshalJSON() ([]byte,error)
typeSslCertsCreateEphemeralCall¶added inv0.52.0
type SslCertsCreateEphemeralCall struct {// contains filtered or unexported fields}func (*SslCertsCreateEphemeralCall)Context¶added inv0.52.0
func (c *SslCertsCreateEphemeralCall) Context(ctxcontext.Context) *SslCertsCreateEphemeralCall
Context sets the context to be used in this call's Do method.
func (*SslCertsCreateEphemeralCall)Do¶added inv0.52.0
func (c *SslCertsCreateEphemeralCall) Do(opts ...googleapi.CallOption) (*SslCert,error)
Do executes the "sql.sslCerts.createEphemeral" call.Any non-2xx status code is an error. Response headers are in either*SslCert.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*SslCertsCreateEphemeralCall)Fields¶added inv0.52.0
func (c *SslCertsCreateEphemeralCall) Fields(s ...googleapi.Field) *SslCertsCreateEphemeralCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*SslCertsCreateEphemeralCall)Header¶added inv0.52.0
func (c *SslCertsCreateEphemeralCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeSslCertsCreateEphemeralRequest¶
type SslCertsCreateEphemeralRequest struct {// AccessToken: Access token to include in the signed certificate.AccessTokenstring `json:"access_token,omitempty"`// PublicKey: PEM encoded public key to include in the signed certificate.PublicKeystring `json:"public_key,omitempty"`// ForceSendFields is a list of field names (e.g. "AccessToken") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AccessToken") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SslCertsCreateEphemeralRequest: SslCerts create ephemeral certificaterequest.
func (SslCertsCreateEphemeralRequest)MarshalJSON¶
func (sSslCertsCreateEphemeralRequest) MarshalJSON() ([]byte,error)
typeSslCertsDeleteCall¶added inv0.52.0
type SslCertsDeleteCall struct {// contains filtered or unexported fields}func (*SslCertsDeleteCall)Context¶added inv0.52.0
func (c *SslCertsDeleteCall) Context(ctxcontext.Context) *SslCertsDeleteCall
Context sets the context to be used in this call's Do method.
func (*SslCertsDeleteCall)Do¶added inv0.52.0
func (c *SslCertsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.sslCerts.delete" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*SslCertsDeleteCall)Fields¶added inv0.52.0
func (c *SslCertsDeleteCall) Fields(s ...googleapi.Field) *SslCertsDeleteCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*SslCertsDeleteCall)Header¶added inv0.52.0
func (c *SslCertsDeleteCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeSslCertsGetCall¶added inv0.52.0
type SslCertsGetCall struct {// contains filtered or unexported fields}func (*SslCertsGetCall)Context¶added inv0.52.0
func (c *SslCertsGetCall) Context(ctxcontext.Context) *SslCertsGetCall
Context sets the context to be used in this call's Do method.
func (*SslCertsGetCall)Do¶added inv0.52.0
func (c *SslCertsGetCall) Do(opts ...googleapi.CallOption) (*SslCert,error)
Do executes the "sql.sslCerts.get" call.Any non-2xx status code is an error. Response headers are in either*SslCert.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*SslCertsGetCall)Fields¶added inv0.52.0
func (c *SslCertsGetCall) Fields(s ...googleapi.Field) *SslCertsGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*SslCertsGetCall)Header¶added inv0.52.0
func (c *SslCertsGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*SslCertsGetCall)IfNoneMatch¶added inv0.52.0
func (c *SslCertsGetCall) IfNoneMatch(entityTagstring) *SslCertsGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeSslCertsInsertCall¶added inv0.52.0
type SslCertsInsertCall struct {// contains filtered or unexported fields}func (*SslCertsInsertCall)Context¶added inv0.52.0
func (c *SslCertsInsertCall) Context(ctxcontext.Context) *SslCertsInsertCall
Context sets the context to be used in this call's Do method.
func (*SslCertsInsertCall)Do¶added inv0.52.0
func (c *SslCertsInsertCall) Do(opts ...googleapi.CallOption) (*SslCertsInsertResponse,error)
Do executes the "sql.sslCerts.insert" call.Any non-2xx status code is an error. Response headers are in either*SslCertsInsertResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*SslCertsInsertCall)Fields¶added inv0.52.0
func (c *SslCertsInsertCall) Fields(s ...googleapi.Field) *SslCertsInsertCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*SslCertsInsertCall)Header¶added inv0.52.0
func (c *SslCertsInsertCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeSslCertsInsertRequest¶added inv0.52.0
type SslCertsInsertRequest struct {// CommonName: User supplied name. Must be a distinct name from the other// certificates for this instance.CommonNamestring `json:"commonName,omitempty"`// ForceSendFields is a list of field names (e.g. "CommonName") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "CommonName") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SslCertsInsertRequest: SslCerts insert request.
func (SslCertsInsertRequest)MarshalJSON¶added inv0.52.0
func (sSslCertsInsertRequest) MarshalJSON() ([]byte,error)
typeSslCertsInsertResponse¶added inv0.52.0
type SslCertsInsertResponse struct {// ClientCert: The new client certificate and private key.ClientCert *SslCertDetail `json:"clientCert,omitempty"`// Kind: This is always `sql#sslCertsInsert`.Kindstring `json:"kind,omitempty"`// Operation: The operation to track the ssl certs insert request.Operation *Operation `json:"operation,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"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "ClientCert") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "ClientCert") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SslCertsInsertResponse: SslCert insert response.
func (SslCertsInsertResponse)MarshalJSON¶added inv0.52.0
func (sSslCertsInsertResponse) MarshalJSON() ([]byte,error)
typeSslCertsListCall¶added inv0.52.0
type SslCertsListCall struct {// contains filtered or unexported fields}func (*SslCertsListCall)Context¶added inv0.52.0
func (c *SslCertsListCall) Context(ctxcontext.Context) *SslCertsListCall
Context sets the context to be used in this call's Do method.
func (*SslCertsListCall)Do¶added inv0.52.0
func (c *SslCertsListCall) Do(opts ...googleapi.CallOption) (*SslCertsListResponse,error)
Do executes the "sql.sslCerts.list" call.Any non-2xx status code is an error. Response headers are in either*SslCertsListResponse.ServerResponse.Header or (if a response was returnedat all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*SslCertsListCall)Fields¶added inv0.52.0
func (c *SslCertsListCall) Fields(s ...googleapi.Field) *SslCertsListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*SslCertsListCall)Header¶added inv0.52.0
func (c *SslCertsListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*SslCertsListCall)IfNoneMatch¶added inv0.52.0
func (c *SslCertsListCall) IfNoneMatch(entityTagstring) *SslCertsListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeSslCertsListResponse¶added inv0.52.0
type SslCertsListResponse struct {// Items: List of client certificates for the instance.Items []*SslCert `json:"items,omitempty"`// Kind: This is always `sql#sslCertsList`.Kindstring `json:"kind,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SslCertsListResponse: SslCerts list response.
func (SslCertsListResponse)MarshalJSON¶added inv0.52.0
func (sSslCertsListResponse) MarshalJSON() ([]byte,error)
typeSslCertsService¶added inv0.52.0
type SslCertsService struct {// contains filtered or unexported fields}funcNewSslCertsService¶added inv0.52.0
func NewSslCertsService(s *Service) *SslCertsService
func (*SslCertsService)CreateEphemeral¶added inv0.52.0
func (r *SslCertsService) CreateEphemeral(projectstring, instancestring, sslcertscreateephemeralrequest *SslCertsCreateEphemeralRequest) *SslCertsCreateEphemeralCall
CreateEphemeral: Generates a short-lived X509 certificate containing theprovided public key and signed by a private key specific to the targetinstance. Users may use the certificate to authenticate as themselves whenconnecting to the database.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the Cloud SQL project.
func (*SslCertsService)Delete¶added inv0.52.0
func (r *SslCertsService) Delete(projectstring, instancestring, sha1Fingerprintstring) *SslCertsDeleteCall
Delete: Deletes the SSL certificate. For First Generation instances, thecertificate remains valid until the instance is restarted.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.- sha1Fingerprint: Sha1 FingerPrint.
func (*SslCertsService)Get¶added inv0.52.0
func (r *SslCertsService) Get(projectstring, instancestring, sha1Fingerprintstring) *SslCertsGetCall
Get: Retrieves a particular SSL certificate. Does not include the privatekey (required for usage). The private key must be saved from the response toinitial creation.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.- sha1Fingerprint: Sha1 FingerPrint.
func (*SslCertsService)Insert¶added inv0.52.0
func (r *SslCertsService) Insert(projectstring, instancestring, sslcertsinsertrequest *SslCertsInsertRequest) *SslCertsInsertCall
Insert: Creates an SSL certificate and returns it along with the private keyand server certificate authority. The new certificate will not be usableuntil the instance is restarted.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*SslCertsService)List¶added inv0.52.0
func (r *SslCertsService) List(projectstring, instancestring) *SslCertsListCall
List: Lists all of the current SSL certificates for the instance.
- instance: Cloud SQL instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
typeStatus¶added inv0.253.0
type Status struct {// Code: The status code, which should be an enum value of google.rpc.Code.Codeint64 `json:"code,omitempty"`// Details: A list of messages that carry the error details. There is a common// set of message types for APIs to use.Details []googleapi.RawMessage `json:"details,omitempty"`// Message: A developer-facing error message, which should be in English. Any// user-facing error message should be localized and sent in the// google.rpc.Status.details field, or localized by the client.Messagestring `json:"message,omitempty"`// ForceSendFields is a list of field names (e.g. "Code") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Code") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Status: The `Status` type defines a logical error model that is suitable fordifferent programming environments, including REST APIs and RPC APIs. It isused by gRPC (https://github.com/grpc). Each `Status` message contains threepieces of data: error code, error message, and error details. You can findout more about this error model and how to work with it in the API DesignGuide (https://cloud.google.com/apis/design/errors).
func (Status)MarshalJSON¶added inv0.253.0
typeSyncFlags¶added inv0.55.0
type SyncFlags struct {// Name: The name of the flag.Namestring `json:"name,omitempty"`// Value: The value of the flag. This field must be omitted if the flag doesn't// take a value.Valuestring `json:"value,omitempty"`// ForceSendFields is a list of field names (e.g. "Name") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Name") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}SyncFlags: Initial sync flags for certain Cloud SQL APIs. Currently used forthe MySQL external server initial dump.
func (SyncFlags)MarshalJSON¶added inv0.55.0
typeTargetMetric¶added inv0.250.0
type TargetMetric struct {// Metric: The metric name to be used for auto scaling.Metricstring `json:"metric,omitempty"`// TargetValue: The target value for the metric.TargetValuefloat64 `json:"targetValue,omitempty"`// ForceSendFields is a list of field names (e.g. "Metric") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Metric") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}TargetMetric: Target metric for read pool auto scaling.
func (TargetMetric)MarshalJSON¶added inv0.250.0
func (sTargetMetric) MarshalJSON() ([]byte,error)
func (*TargetMetric)UnmarshalJSON¶added inv0.250.0
func (s *TargetMetric) UnmarshalJSON(data []byte)error
typeTier¶added inv0.52.0
type Tier struct {// DiskQuota: The maximum disk size of this tier in bytes.DiskQuotaint64 `json:"DiskQuota,omitempty,string"`// RAM: The maximum RAM usage of this tier in bytes.RAMint64 `json:"RAM,omitempty,string"`// Kind: This is always `sql#tier`.Kindstring `json:"kind,omitempty"`// Region: The applicable regions for this tier.Region []string `json:"region,omitempty"`// Tier: An identifier for the machine type, for example, `db-custom-1-3840`.// For related information, see Pricing (/sql/pricing).Tierstring `json:"tier,omitempty"`// ForceSendFields is a list of field names (e.g. "DiskQuota") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DiskQuota") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Tier: A Google Cloud SQL service tier resource.
func (Tier)MarshalJSON¶added inv0.52.0
typeTiersListCall¶added inv0.52.0
type TiersListCall struct {// contains filtered or unexported fields}func (*TiersListCall)Context¶added inv0.52.0
func (c *TiersListCall) Context(ctxcontext.Context) *TiersListCall
Context sets the context to be used in this call's Do method.
func (*TiersListCall)Do¶added inv0.52.0
func (c *TiersListCall) Do(opts ...googleapi.CallOption) (*TiersListResponse,error)
Do executes the "sql.tiers.list" call.Any non-2xx status code is an error. Response headers are in either*TiersListResponse.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*TiersListCall)Fields¶added inv0.52.0
func (c *TiersListCall) Fields(s ...googleapi.Field) *TiersListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*TiersListCall)Header¶added inv0.52.0
func (c *TiersListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*TiersListCall)IfNoneMatch¶added inv0.52.0
func (c *TiersListCall) IfNoneMatch(entityTagstring) *TiersListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeTiersListResponse¶added inv0.52.0
type TiersListResponse struct {// Items: List of tiers.Items []*Tier `json:"items,omitempty"`// Kind: This is always `sql#tiersList`.Kindstring `json:"kind,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}TiersListResponse: Tiers list response.
func (TiersListResponse)MarshalJSON¶added inv0.52.0
func (sTiersListResponse) MarshalJSON() ([]byte,error)
typeTiersService¶added inv0.52.0
type TiersService struct {// contains filtered or unexported fields}funcNewTiersService¶added inv0.52.0
func NewTiersService(s *Service) *TiersService
func (*TiersService)List¶added inv0.52.0
func (r *TiersService) List(projectstring) *TiersListCall
List: Lists all available machine types (tiers) for Cloud SQL, for example,`db-custom-1-3840`. For more information, seehttps://cloud.google.com/sql/pricing.
- project: Project ID of the project for which to list tiers.
typeTruncateLogContext¶added inv0.52.0
type TruncateLogContext struct {// Kind: This is always `sql#truncateLogContext`.Kindstring `json:"kind,omitempty"`// LogType: The type of log to truncate. Valid values are `MYSQL_GENERAL_TABLE`// and `MYSQL_SLOW_TABLE`.LogTypestring `json:"logType,omitempty"`// ForceSendFields is a list of field names (e.g. "Kind") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Kind") to include in API requests// with the JSON null value. By default, fields with empty values are omitted// from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}TruncateLogContext: Database Instance truncate log context.
func (TruncateLogContext)MarshalJSON¶added inv0.52.0
func (sTruncateLogContext) MarshalJSON() ([]byte,error)
typeUser¶added inv0.52.0
type User struct {// DatabaseRoles: Optional. Role memberships of the userDatabaseRoles []string `json:"databaseRoles,omitempty"`// DualPasswordType: Dual password status for the user.//// Possible values:// "DUAL_PASSWORD_TYPE_UNSPECIFIED" - The default value.// "NO_MODIFY_DUAL_PASSWORD" - Do not update the user's dual password status.// "NO_DUAL_PASSWORD" - No dual password usable for connecting using this// user.// "DUAL_PASSWORD" - Dual password usable for connecting using this user.DualPasswordTypestring `json:"dualPasswordType,omitempty"`// Etag: This field is deprecated and will be removed from a future version of// the API.Etagstring `json:"etag,omitempty"`// Host: Optional. The host from which the user can connect. For `insert`// operations, host defaults to an empty string. For `update` operations, host// is specified as part of the request URL. The host name cannot be updated// after insertion. For a MySQL instance, it's required; for a PostgreSQL or// SQL Server instance, it's optional.Hoststring `json:"host,omitempty"`// IamEmail: Optional. The full email for an IAM user. For normal database// users, this will not be filled. Only applicable to MySQL database users.IamEmailstring `json:"iamEmail,omitempty"`// IamStatus: Indicates if a group is active or inactive for IAM database// authentication.//// Possible values:// "IAM_STATUS_UNSPECIFIED" - The default value for users that are not of// type CLOUD_IAM_GROUP. Only CLOUD_IAM_GROUP users will be inactive or active.// Users with an IamStatus of IAM_STATUS_UNSPECIFIED will not display whether// they are active or inactive as that is not applicable to them.// "INACTIVE" - INACTIVE indicates a group is not available for IAM database// authentication.// "ACTIVE" - ACTIVE indicates a group is available for IAM database// authentication.IamStatusstring `json:"iamStatus,omitempty"`// Instance: The name of the Cloud SQL instance. This does not include the// project ID. Can be omitted for `update` because it is already specified on// the URL.Instancestring `json:"instance,omitempty"`// Kind: This is always `sql#user`.Kindstring `json:"kind,omitempty"`// Name: The name of the user in the Cloud SQL instance. Can be omitted for// `update` because it is already specified in the URL.Namestring `json:"name,omitempty"`// Password: The password for the user.Passwordstring `json:"password,omitempty"`// PasswordPolicy: User level password validation policy.PasswordPolicy *UserPasswordValidationPolicy `json:"passwordPolicy,omitempty"`// Project: The project ID of the project containing the Cloud SQL database.// The Google apps domain is prefixed if applicable. Can be omitted for// `update` because it is already specified on the URL.Projectstring `json:"project,omitempty"`SqlserverUserDetails *SqlServerUserDetails `json:"sqlserverUserDetails,omitempty"`// Type: The user type. It determines the method to authenticate the user// during login. The default is the database's built-in user type.//// Possible values:// "BUILT_IN" - The database's built-in user type.// "CLOUD_IAM_USER" - Cloud IAM user.// "CLOUD_IAM_SERVICE_ACCOUNT" - Cloud IAM service account.// "CLOUD_IAM_GROUP" - Cloud IAM group. Not used for login.// "CLOUD_IAM_GROUP_USER" - Read-only. Login for a user that belongs to the// Cloud IAM group.// "CLOUD_IAM_GROUP_SERVICE_ACCOUNT" - Read-only. Login for a service account// that belongs to the Cloud IAM group.// "ENTRAID_USER" - Microsoft Entra ID user.Typestring `json:"type,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "DatabaseRoles") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "DatabaseRoles") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}User: A Cloud SQL user resource.
func (User)MarshalJSON¶added inv0.52.0
typeUserPasswordValidationPolicy¶added inv0.61.0
type UserPasswordValidationPolicy struct {// AllowedFailedAttempts: Number of failed login attempts allowed before user// get locked.AllowedFailedAttemptsint64 `json:"allowedFailedAttempts,omitempty"`// EnableFailedAttemptsCheck: If true, failed login attempts check will be// enabled.EnableFailedAttemptsCheckbool `json:"enableFailedAttemptsCheck,omitempty"`// EnablePasswordVerification: If true, the user must specify the current// password before changing the password. This flag is supported only for// MySQL.EnablePasswordVerificationbool `json:"enablePasswordVerification,omitempty"`// PasswordExpirationDuration: Expiration duration after password is updated.PasswordExpirationDurationstring `json:"passwordExpirationDuration,omitempty"`// Status: Output only. Read-only password status.Status *PasswordStatus `json:"status,omitempty"`// ForceSendFields is a list of field names (e.g. "AllowedFailedAttempts") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "AllowedFailedAttempts") to// include in API requests with the JSON null value. By default, fields with// empty values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}UserPasswordValidationPolicy: User level password validation policy.
func (UserPasswordValidationPolicy)MarshalJSON¶added inv0.61.0
func (sUserPasswordValidationPolicy) MarshalJSON() ([]byte,error)
typeUsersDeleteCall¶added inv0.52.0
type UsersDeleteCall struct {// contains filtered or unexported fields}func (*UsersDeleteCall)Context¶added inv0.52.0
func (c *UsersDeleteCall) Context(ctxcontext.Context) *UsersDeleteCall
Context sets the context to be used in this call's Do method.
func (*UsersDeleteCall)Do¶added inv0.52.0
func (c *UsersDeleteCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.users.delete" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*UsersDeleteCall)Fields¶added inv0.52.0
func (c *UsersDeleteCall) Fields(s ...googleapi.Field) *UsersDeleteCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*UsersDeleteCall)Header¶added inv0.52.0
func (c *UsersDeleteCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*UsersDeleteCall)Host¶added inv0.52.0
func (c *UsersDeleteCall) Host(hoststring) *UsersDeleteCall
Host sets the optional parameter "host": Host of the user in the instance.
func (*UsersDeleteCall)Name¶added inv0.52.0
func (c *UsersDeleteCall) Name(namestring) *UsersDeleteCall
Name sets the optional parameter "name": Name of the user in the instance.
typeUsersGetCall¶added inv0.87.0
type UsersGetCall struct {// contains filtered or unexported fields}func (*UsersGetCall)Context¶added inv0.87.0
func (c *UsersGetCall) Context(ctxcontext.Context) *UsersGetCall
Context sets the context to be used in this call's Do method.
func (*UsersGetCall)Do¶added inv0.87.0
func (c *UsersGetCall) Do(opts ...googleapi.CallOption) (*User,error)
Do executes the "sql.users.get" call.Any non-2xx status code is an error. Response headers are in either*User.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*UsersGetCall)Fields¶added inv0.87.0
func (c *UsersGetCall) Fields(s ...googleapi.Field) *UsersGetCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*UsersGetCall)Header¶added inv0.87.0
func (c *UsersGetCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*UsersGetCall)Host¶added inv0.101.0
func (c *UsersGetCall) Host(hoststring) *UsersGetCall
Host sets the optional parameter "host": Host of a user of the instance.
func (*UsersGetCall)IfNoneMatch¶added inv0.87.0
func (c *UsersGetCall) IfNoneMatch(entityTagstring) *UsersGetCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeUsersInsertCall¶added inv0.52.0
type UsersInsertCall struct {// contains filtered or unexported fields}func (*UsersInsertCall)Context¶added inv0.52.0
func (c *UsersInsertCall) Context(ctxcontext.Context) *UsersInsertCall
Context sets the context to be used in this call's Do method.
func (*UsersInsertCall)Do¶added inv0.52.0
func (c *UsersInsertCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.users.insert" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*UsersInsertCall)Fields¶added inv0.52.0
func (c *UsersInsertCall) Fields(s ...googleapi.Field) *UsersInsertCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*UsersInsertCall)Header¶added inv0.52.0
func (c *UsersInsertCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
typeUsersListCall¶added inv0.52.0
type UsersListCall struct {// contains filtered or unexported fields}func (*UsersListCall)Context¶added inv0.52.0
func (c *UsersListCall) Context(ctxcontext.Context) *UsersListCall
Context sets the context to be used in this call's Do method.
func (*UsersListCall)Do¶added inv0.52.0
func (c *UsersListCall) Do(opts ...googleapi.CallOption) (*UsersListResponse,error)
Do executes the "sql.users.list" call.Any non-2xx status code is an error. Response headers are in either*UsersListResponse.ServerResponse.Header or (if a response was returned atall) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified tocheck whether the returned error was because http.StatusNotModified wasreturned.
func (*UsersListCall)Fields¶added inv0.52.0
func (c *UsersListCall) Fields(s ...googleapi.Field) *UsersListCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*UsersListCall)Header¶added inv0.52.0
func (c *UsersListCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*UsersListCall)IfNoneMatch¶added inv0.52.0
func (c *UsersListCall) IfNoneMatch(entityTagstring) *UsersListCall
IfNoneMatch sets an optional parameter which makes the operation fail if theobject's ETag matches the given value. This is useful for getting updatesonly after the object has changed since the last request.
typeUsersListResponse¶added inv0.52.0
type UsersListResponse struct {// Items: List of user resources in the instance.Items []*User `json:"items,omitempty"`// Kind: This is always `sql#usersList`.Kindstring `json:"kind,omitempty"`// NextPageToken: Unused.NextPageTokenstring `json:"nextPageToken,omitempty"`// ServerResponse contains the HTTP response code and headers from the server.googleapi.ServerResponse `json:"-"`// ForceSendFields is a list of field names (e.g. "Items") to unconditionally// include in API requests. By default, fields with empty or default values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "Items") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}UsersListResponse: User list response.
func (UsersListResponse)MarshalJSON¶added inv0.52.0
func (sUsersListResponse) MarshalJSON() ([]byte,error)
typeUsersService¶added inv0.52.0
type UsersService struct {// contains filtered or unexported fields}funcNewUsersService¶added inv0.52.0
func NewUsersService(s *Service) *UsersService
func (*UsersService)Delete¶added inv0.52.0
func (r *UsersService) Delete(projectstring, instancestring) *UsersDeleteCall
Delete: Deletes a user from a Cloud SQL instance.
- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*UsersService)Get¶added inv0.87.0
func (r *UsersService) Get(projectstring, instancestring, namestring) *UsersGetCall
Get: Retrieves a resource containing information about a user.
- instance: Database instance ID. This does not include the project ID.- name: User of the instance.- project: Project ID of the project that contains the instance.
func (*UsersService)Insert¶added inv0.52.0
func (r *UsersService) Insert(projectstring, instancestring, user *User) *UsersInsertCall
Insert: Creates a new user in a Cloud SQL instance.
- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*UsersService)List¶added inv0.52.0
func (r *UsersService) List(projectstring, instancestring) *UsersListCall
List: Lists users in the specified Cloud SQL instance.
- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
func (*UsersService)Update¶added inv0.52.0
func (r *UsersService) Update(projectstring, instancestring, user *User) *UsersUpdateCall
Update: Updates an existing user in a Cloud SQL instance.
- instance: Database instance ID. This does not include the project ID.- project: Project ID of the project that contains the instance.
typeUsersUpdateCall¶added inv0.52.0
type UsersUpdateCall struct {// contains filtered or unexported fields}func (*UsersUpdateCall)Context¶added inv0.52.0
func (c *UsersUpdateCall) Context(ctxcontext.Context) *UsersUpdateCall
Context sets the context to be used in this call's Do method.
func (*UsersUpdateCall)DatabaseRoles¶added inv0.257.0
func (c *UsersUpdateCall) DatabaseRoles(databaseRoles ...string) *UsersUpdateCall
DatabaseRoles sets the optional parameter "databaseRoles": List of databaseroles to grant to the user. body.database_roles will be ignored for updaterequest.
func (*UsersUpdateCall)Do¶added inv0.52.0
func (c *UsersUpdateCall) Do(opts ...googleapi.CallOption) (*Operation,error)
Do executes the "sql.users.update" call.Any non-2xx status code is an error. Response headers are in either*Operation.ServerResponse.Header or (if a response was returned at all) inerror.(*googleapi.Error).Header. Use googleapi.IsNotModified to checkwhether the returned error was because http.StatusNotModified was returned.
func (*UsersUpdateCall)Fields¶added inv0.52.0
func (c *UsersUpdateCall) Fields(s ...googleapi.Field) *UsersUpdateCall
Fields allows partial responses to be retrieved. Seehttps://developers.google.com/gdata/docs/2.0/basics#PartialResponse for moredetails.
func (*UsersUpdateCall)Header¶added inv0.52.0
func (c *UsersUpdateCall) Header()http.Header
Header returns a http.Header that can be modified by the caller to addheaders to the request.
func (*UsersUpdateCall)Host¶added inv0.52.0
func (c *UsersUpdateCall) Host(hoststring) *UsersUpdateCall
Host sets the optional parameter "host": Host of the user in the instance.
func (*UsersUpdateCall)Name¶added inv0.52.0
func (c *UsersUpdateCall) Name(namestring) *UsersUpdateCall
Name sets the optional parameter "name": Name of the user in the instance.
typeValue¶added inv0.248.0
type Value struct {// NullValue: If cell value is null, then this flag will be set to true.NullValuebool `json:"nullValue,omitempty"`// Value: The cell value in string format.Valuestring `json:"value,omitempty"`// ForceSendFields is a list of field names (e.g. "NullValue") to// unconditionally include in API requests. By default, fields with empty or// default values are omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more// details.ForceSendFields []string `json:"-"`// NullFields is a list of field names (e.g. "NullValue") to include in API// requests with the JSON null value. By default, fields with empty values are// omitted from API requests. See//https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.NullFields []string `json:"-"`}Value: The cell value of the table.