Documentation ¶
Overview ¶
Package rdb provides methods and message types of the rdb v1 API.
Index ¶
- Constants
- type ACLRule
- type ACLRuleAction
- type ACLRuleDirection
- type ACLRuleProtocol
- type ACLRuleRequest
- type API
- func (s *API) AddInstanceACLRules(req *AddInstanceACLRulesRequest, opts ...scw.RequestOption) (*AddInstanceACLRulesResponse, error)
- func (s *API) AddInstanceSettings(req *AddInstanceSettingsRequest, opts ...scw.RequestOption) (*AddInstanceSettingsResponse, error)
- func (s *API) ApplyInstanceMaintenance(req *ApplyInstanceMaintenanceRequest, opts ...scw.RequestOption) (*Maintenance, error)
- func (s *API) CloneInstance(req *CloneInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) CreateDatabase(req *CreateDatabaseRequest, opts ...scw.RequestOption) (*Database, error)
- func (s *API) CreateDatabaseBackup(req *CreateDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
- func (s *API) CreateEndpoint(req *CreateEndpointRequest, opts ...scw.RequestOption) (*Endpoint, error)
- func (s *API) CreateInstance(req *CreateInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) CreateInstanceFromSnapshot(req *CreateInstanceFromSnapshotRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) CreateReadReplica(req *CreateReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
- func (s *API) CreateReadReplicaEndpoint(req *CreateReadReplicaEndpointRequest, opts ...scw.RequestOption) (*ReadReplica, error)
- func (s *API) CreateSnapshot(req *CreateSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
- func (s *API) CreateUser(req *CreateUserRequest, opts ...scw.RequestOption) (*User, error)
- func (s *API) DeleteDatabase(req *DeleteDatabaseRequest, opts ...scw.RequestOption) error
- func (s *API) DeleteDatabaseBackup(req *DeleteDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
- func (s *API) DeleteEndpoint(req *DeleteEndpointRequest, opts ...scw.RequestOption) error
- func (s *API) DeleteInstance(req *DeleteInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) DeleteInstanceACLRules(req *DeleteInstanceACLRulesRequest, opts ...scw.RequestOption) (*DeleteInstanceACLRulesResponse, error)
- func (s *API) DeleteInstanceSettings(req *DeleteInstanceSettingsRequest, opts ...scw.RequestOption) (*DeleteInstanceSettingsResponse, error)
- func (s *API) DeleteReadReplica(req *DeleteReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
- func (s *API) DeleteSnapshot(req *DeleteSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
- func (s *API) DeleteUser(req *DeleteUserRequest, opts ...scw.RequestOption) error
- func (s *API) ExportDatabaseBackup(req *ExportDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
- func (s *API) GetDatabaseBackup(req *GetDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
- func (s *API) GetEndpoint(req *GetEndpointRequest, opts ...scw.RequestOption) (*Endpoint, error)
- func (s *API) GetInstance(req *GetInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) GetInstanceCertificate(req *GetInstanceCertificateRequest, opts ...scw.RequestOption) (*scw.File, error)
- func (s *API) GetInstanceLog(req *GetInstanceLogRequest, opts ...scw.RequestOption) (*InstanceLog, error)
- func (s *API) GetInstanceMetrics(req *GetInstanceMetricsRequest, opts ...scw.RequestOption) (*InstanceMetrics, error)
- func (s *API) GetReadReplica(req *GetReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
- func (s *API) GetSnapshot(req *GetSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
- func (s *API) ListDatabaseBackups(req *ListDatabaseBackupsRequest, opts ...scw.RequestOption) (*ListDatabaseBackupsResponse, error)
- func (s *API) ListDatabaseEngines(req *ListDatabaseEnginesRequest, opts ...scw.RequestOption) (*ListDatabaseEnginesResponse, error)
- func (s *API) ListDatabases(req *ListDatabasesRequest, opts ...scw.RequestOption) (*ListDatabasesResponse, error)
- func (s *API) ListInstanceACLRules(req *ListInstanceACLRulesRequest, opts ...scw.RequestOption) (*ListInstanceACLRulesResponse, error)
- func (s *API) ListInstanceLogs(req *ListInstanceLogsRequest, opts ...scw.RequestOption) (*ListInstanceLogsResponse, error)
- func (s *API) ListInstanceLogsDetails(req *ListInstanceLogsDetailsRequest, opts ...scw.RequestOption) (*ListInstanceLogsDetailsResponse, error)
- func (s *API) ListInstances(req *ListInstancesRequest, opts ...scw.RequestOption) (*ListInstancesResponse, error)
- func (s *API) ListNodeTypes(req *ListNodeTypesRequest, opts ...scw.RequestOption) (*ListNodeTypesResponse, error)
- func (s *API) ListPrivileges(req *ListPrivilegesRequest, opts ...scw.RequestOption) (*ListPrivilegesResponse, error)
- func (s *API) ListSnapshots(req *ListSnapshotsRequest, opts ...scw.RequestOption) (*ListSnapshotsResponse, error)
- func (s *API) ListUsers(req *ListUsersRequest, opts ...scw.RequestOption) (*ListUsersResponse, error)
- func (s *API) MigrateEndpoint(req *MigrateEndpointRequest, opts ...scw.RequestOption) (*Endpoint, error)
- func (s *API) PrepareInstanceLogs(req *PrepareInstanceLogsRequest, opts ...scw.RequestOption) (*PrepareInstanceLogsResponse, error)
- func (s *API) PromoteReadReplica(req *PromoteReadReplicaRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) PurgeInstanceLogs(req *PurgeInstanceLogsRequest, opts ...scw.RequestOption) error
- func (s *API) Regions() []scw.Region
- func (s *API) RenewInstanceCertificate(req *RenewInstanceCertificateRequest, opts ...scw.RequestOption) error
- func (s *API) ResetReadReplica(req *ResetReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
- func (s *API) RestartInstance(req *RestartInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) RestoreDatabaseBackup(req *RestoreDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
- func (s *API) SetInstanceACLRules(req *SetInstanceACLRulesRequest, opts ...scw.RequestOption) (*SetInstanceACLRulesResponse, error)
- func (s *API) SetInstanceSettings(req *SetInstanceSettingsRequest, opts ...scw.RequestOption) (*SetInstanceSettingsResponse, error)
- func (s *API) SetPrivilege(req *SetPrivilegeRequest, opts ...scw.RequestOption) (*Privilege, error)
- func (s *API) UpdateDatabaseBackup(req *UpdateDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
- func (s *API) UpdateInstance(req *UpdateInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) UpdateSnapshot(req *UpdateSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
- func (s *API) UpdateUser(req *UpdateUserRequest, opts ...scw.RequestOption) (*User, error)
- func (s *API) UpgradeInstance(req *UpgradeInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) WaitForDatabaseBackup(req *WaitForDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
- func (s *API) WaitForInstance(req *WaitForInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
- func (s *API) WaitForInstanceLog(req *WaitForInstanceLogRequest, opts ...scw.RequestOption) (*InstanceLog, error)
- func (s *API) WaitForReadReplica(req *WaitForReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
- type AddInstanceACLRulesRequest
- type AddInstanceACLRulesResponse
- type AddInstanceSettingsRequest
- type AddInstanceSettingsResponse
- type ApplyInstanceMaintenanceRequest
- type BackupSchedule
- type CloneInstanceRequest
- type CreateDatabaseBackupRequest
- type CreateDatabaseRequest
- type CreateEndpointRequest
- type CreateInstanceFromSnapshotRequest
- type CreateInstanceRequest
- type CreateReadReplicaEndpointRequest
- type CreateReadReplicaRequest
- type CreateSnapshotRequest
- type CreateUserRequest
- type Database
- type DatabaseBackup
- type DatabaseBackupStatus
- type DatabaseEngine
- type DeleteDatabaseBackupRequest
- type DeleteDatabaseRequest
- type DeleteEndpointRequest
- type DeleteInstanceACLRulesRequest
- type DeleteInstanceACLRulesResponse
- type DeleteInstanceRequest
- type DeleteInstanceSettingsRequest
- type DeleteInstanceSettingsResponse
- type DeleteReadReplicaRequest
- type DeleteSnapshotRequest
- type DeleteUserRequest
- type EncryptionAtRest
- type Endpoint
- type EndpointDirectAccessDetails
- type EndpointLoadBalancerDetails
- type EndpointPrivateNetworkDetails
- type EndpointPrivateNetworkDetailsProvisioningMode
- func (enum EndpointPrivateNetworkDetailsProvisioningMode) MarshalJSON() ([]byte, error)
- func (enum EndpointPrivateNetworkDetailsProvisioningMode) String() string
- func (enum *EndpointPrivateNetworkDetailsProvisioningMode) UnmarshalJSON(data []byte) error
- func (enum EndpointPrivateNetworkDetailsProvisioningMode) Values() []EndpointPrivateNetworkDetailsProvisioningMode
- type EndpointSpec
- type EndpointSpecLoadBalancer
- type EndpointSpecPrivateNetwork
- type EndpointSpecPrivateNetworkIpamConfig
- type EngineSetting
- type EngineSettingPropertyType
- type EngineVersion
- type ExportDatabaseBackupRequest
- type GetDatabaseBackupRequest
- type GetEndpointRequest
- type GetInstanceCertificateRequest
- type GetInstanceLogRequest
- type GetInstanceMetricsRequest
- type GetInstanceRequest
- type GetReadReplicaRequest
- type GetSnapshotRequest
- type Instance
- type InstanceLog
- type InstanceLogStatus
- type InstanceMetrics
- type InstanceSetting
- type InstanceStatus
- type ListDatabaseBackupsRequest
- type ListDatabaseBackupsRequestOrderBy
- func (enum ListDatabaseBackupsRequestOrderBy) MarshalJSON() ([]byte, error)
- func (enum ListDatabaseBackupsRequestOrderBy) String() string
- func (enum *ListDatabaseBackupsRequestOrderBy) UnmarshalJSON(data []byte) error
- func (enum ListDatabaseBackupsRequestOrderBy) Values() []ListDatabaseBackupsRequestOrderBy
- type ListDatabaseBackupsResponse
- type ListDatabaseEnginesRequest
- type ListDatabaseEnginesResponse
- type ListDatabasesRequest
- type ListDatabasesRequestOrderBy
- type ListDatabasesResponse
- type ListInstanceACLRulesRequest
- type ListInstanceACLRulesResponse
- type ListInstanceLogsDetailsRequest
- type ListInstanceLogsDetailsResponse
- type ListInstanceLogsDetailsResponseInstanceLogDetail
- type ListInstanceLogsRequest
- type ListInstanceLogsRequestOrderBy
- type ListInstanceLogsResponse
- type ListInstancesRequest
- type ListInstancesRequestOrderBy
- type ListInstancesResponse
- type ListNodeTypesRequest
- type ListNodeTypesResponse
- type ListPrivilegesRequest
- type ListPrivilegesRequestOrderBy
- type ListPrivilegesResponse
- type ListSnapshotsRequest
- type ListSnapshotsRequestOrderBy
- type ListSnapshotsResponse
- type ListUsersRequest
- type ListUsersRequestOrderBy
- type ListUsersResponse
- type LogsPolicy
- type Maintenance
- type MaintenanceStatus
- type MigrateEndpointRequest
- type NodeType
- type NodeTypeGeneration
- type NodeTypeStock
- type NodeTypeVolumeConstraintSizes
- type NodeTypeVolumeType
- type Permission
- type PrepareInstanceLogsRequest
- type PrepareInstanceLogsResponse
- type Privilege
- type PromoteReadReplicaRequest
- type PurgeInstanceLogsRequest
- type ReadReplica
- type ReadReplicaEndpointSpec
- type ReadReplicaEndpointSpecDirectAccess
- type ReadReplicaEndpointSpecPrivateNetwork
- type ReadReplicaEndpointSpecPrivateNetworkIpamConfig
- type ReadReplicaStatus
- type RenewInstanceCertificateRequest
- type ResetReadReplicaRequest
- type RestartInstanceRequest
- type RestoreDatabaseBackupRequest
- type SetInstanceACLRulesRequest
- type SetInstanceACLRulesResponse
- type SetInstanceSettingsRequest
- type SetInstanceSettingsResponse
- type SetPrivilegeRequest
- type Snapshot
- type SnapshotStatus
- type SnapshotVolumeType
- type StorageClass
- type UpdateDatabaseBackupRequest
- type UpdateInstanceRequest
- type UpdateSnapshotRequest
- type UpdateUserRequest
- type UpgradableVersion
- type UpgradeInstanceRequest
- type UpgradeInstanceRequestMajorUpgradeWorkflow
- type User
- type Volume
- type VolumeType
- type WaitForDatabaseBackupRequest
- type WaitForInstanceLogRequest
- type WaitForInstanceRequest
- type WaitForReadReplicaRequest
Constants ¶
const ( ACLRuleActionAllow = ACLRuleAction("allow") ACLRuleActionDeny = ACLRuleAction("deny") )
const ( ACLRuleDirectionInbound = ACLRuleDirection("inbound") ACLRuleDirectionOutbound = ACLRuleDirection("outbound") )
const ( ACLRuleProtocolTCP = ACLRuleProtocol("tcp") ACLRuleProtocolUDP = ACLRuleProtocol("udp") ACLRuleProtocolIcmp = ACLRuleProtocol("icmp") )
const ( DatabaseBackupStatusUnknown = DatabaseBackupStatus("unknown") DatabaseBackupStatusCreating = DatabaseBackupStatus("creating") DatabaseBackupStatusReady = DatabaseBackupStatus("ready") DatabaseBackupStatusRestoring = DatabaseBackupStatus("restoring") DatabaseBackupStatusDeleting = DatabaseBackupStatus("deleting") DatabaseBackupStatusError = DatabaseBackupStatus("error") DatabaseBackupStatusExporting = DatabaseBackupStatus("exporting") DatabaseBackupStatusLocked = DatabaseBackupStatus("locked") )
const ( EndpointPrivateNetworkDetailsProvisioningModeStatic = EndpointPrivateNetworkDetailsProvisioningMode("static") EndpointPrivateNetworkDetailsProvisioningModeIpam = EndpointPrivateNetworkDetailsProvisioningMode("ipam") )
const ( EngineSettingPropertyTypeBOOLEAN = EngineSettingPropertyType("BOOLEAN") EngineSettingPropertyTypeINT = EngineSettingPropertyType("INT") EngineSettingPropertyTypeSTRING = EngineSettingPropertyType("STRING") EngineSettingPropertyTypeFLOAT = EngineSettingPropertyType("FLOAT") )
const ( InstanceLogStatusUnknown = InstanceLogStatus("unknown") InstanceLogStatusReady = InstanceLogStatus("ready") InstanceLogStatusCreating = InstanceLogStatus("creating") InstanceLogStatusError = InstanceLogStatus("error") )
const ( InstanceStatusUnknown = InstanceStatus("unknown") InstanceStatusReady = InstanceStatus("ready") InstanceStatusProvisioning = InstanceStatus("provisioning") InstanceStatusConfiguring = InstanceStatus("configuring") InstanceStatusDeleting = InstanceStatus("deleting") InstanceStatusError = InstanceStatus("error") InstanceStatusAutohealing = InstanceStatus("autohealing") InstanceStatusLocked = InstanceStatus("locked") InstanceStatusInitializing = InstanceStatus("initializing") InstanceStatusDiskFull = InstanceStatus("disk_full") InstanceStatusBackuping = InstanceStatus("backuping") InstanceStatusSnapshotting = InstanceStatus("snapshotting") InstanceStatusRestarting = InstanceStatus("restarting") )
const ( ListDatabaseBackupsRequestOrderByCreatedAtAsc = ListDatabaseBackupsRequestOrderBy("created_at_asc") ListDatabaseBackupsRequestOrderByCreatedAtDesc = ListDatabaseBackupsRequestOrderBy("created_at_desc") ListDatabaseBackupsRequestOrderByNameAsc = ListDatabaseBackupsRequestOrderBy("name_asc") ListDatabaseBackupsRequestOrderByNameDesc = ListDatabaseBackupsRequestOrderBy("name_desc") ListDatabaseBackupsRequestOrderByStatusAsc = ListDatabaseBackupsRequestOrderBy("status_asc") ListDatabaseBackupsRequestOrderByStatusDesc = ListDatabaseBackupsRequestOrderBy("status_desc") )
const ( ListDatabasesRequestOrderByNameAsc = ListDatabasesRequestOrderBy("name_asc") ListDatabasesRequestOrderByNameDesc = ListDatabasesRequestOrderBy("name_desc") ListDatabasesRequestOrderBySizeAsc = ListDatabasesRequestOrderBy("size_asc") ListDatabasesRequestOrderBySizeDesc = ListDatabasesRequestOrderBy("size_desc") )
const ( ListInstanceLogsRequestOrderByCreatedAtAsc = ListInstanceLogsRequestOrderBy("created_at_asc") ListInstanceLogsRequestOrderByCreatedAtDesc = ListInstanceLogsRequestOrderBy("created_at_desc") )
const ( ListInstancesRequestOrderByCreatedAtAsc = ListInstancesRequestOrderBy("created_at_asc") ListInstancesRequestOrderByCreatedAtDesc = ListInstancesRequestOrderBy("created_at_desc") ListInstancesRequestOrderByNameAsc = ListInstancesRequestOrderBy("name_asc") ListInstancesRequestOrderByNameDesc = ListInstancesRequestOrderBy("name_desc") ListInstancesRequestOrderByRegion = ListInstancesRequestOrderBy("region") ListInstancesRequestOrderByStatusAsc = ListInstancesRequestOrderBy("status_asc") ListInstancesRequestOrderByStatusDesc = ListInstancesRequestOrderBy("status_desc") )
const ( ListPrivilegesRequestOrderByUserNameAsc = ListPrivilegesRequestOrderBy("user_name_asc") ListPrivilegesRequestOrderByUserNameDesc = ListPrivilegesRequestOrderBy("user_name_desc") ListPrivilegesRequestOrderByDatabaseNameAsc = ListPrivilegesRequestOrderBy("database_name_asc") ListPrivilegesRequestOrderByDatabaseNameDesc = ListPrivilegesRequestOrderBy("database_name_desc") )
const ( ListSnapshotsRequestOrderByCreatedAtAsc = ListSnapshotsRequestOrderBy("created_at_asc") ListSnapshotsRequestOrderByCreatedAtDesc = ListSnapshotsRequestOrderBy("created_at_desc") ListSnapshotsRequestOrderByNameAsc = ListSnapshotsRequestOrderBy("name_asc") ListSnapshotsRequestOrderByNameDesc = ListSnapshotsRequestOrderBy("name_desc") ListSnapshotsRequestOrderByExpiresAtAsc = ListSnapshotsRequestOrderBy("expires_at_asc") ListSnapshotsRequestOrderByExpiresAtDesc = ListSnapshotsRequestOrderBy("expires_at_desc") )
const ( ListUsersRequestOrderByNameAsc = ListUsersRequestOrderBy("name_asc") ListUsersRequestOrderByNameDesc = ListUsersRequestOrderBy("name_desc") ListUsersRequestOrderByIsAdminAsc = ListUsersRequestOrderBy("is_admin_asc") ListUsersRequestOrderByIsAdminDesc = ListUsersRequestOrderBy("is_admin_desc") )
const ( MaintenanceStatusUnknown = MaintenanceStatus("unknown") MaintenanceStatusPending = MaintenanceStatus("pending") MaintenanceStatusDone = MaintenanceStatus("done") MaintenanceStatusCanceled = MaintenanceStatus("canceled") MaintenanceStatusOngoing = MaintenanceStatus("ongoing") )
const ( NodeTypeGenerationUnknownGeneration = NodeTypeGeneration("unknown_generation") NodeTypeGenerationGenerationV1 = NodeTypeGeneration("generation_v1") NodeTypeGenerationGenerationV2 = NodeTypeGeneration("generation_v2") )
const ( NodeTypeStockUnknown = NodeTypeStock("unknown") NodeTypeStockLowStock = NodeTypeStock("low_stock") NodeTypeStockOutOfStock = NodeTypeStock("out_of_stock") NodeTypeStockAvailable = NodeTypeStock("available") )
const ( PermissionReadonly = Permission("readonly") PermissionReadwrite = Permission("readwrite") PermissionAll = Permission("all") PermissionCustom = Permission("custom") PermissionNone = Permission("none") )
const ( ReadReplicaStatusUnknown = ReadReplicaStatus("unknown") ReadReplicaStatusProvisioning = ReadReplicaStatus("provisioning") ReadReplicaStatusInitializing = ReadReplicaStatus("initializing") ReadReplicaStatusReady = ReadReplicaStatus("ready") ReadReplicaStatusDeleting = ReadReplicaStatus("deleting") ReadReplicaStatusError = ReadReplicaStatus("error") ReadReplicaStatusLocked = ReadReplicaStatus("locked") ReadReplicaStatusConfiguring = ReadReplicaStatus("configuring") ReadReplicaStatusPromoting = ReadReplicaStatus("promoting") )
const ( SnapshotStatusUnknown = SnapshotStatus("unknown") SnapshotStatusCreating = SnapshotStatus("creating") SnapshotStatusReady = SnapshotStatus("ready") SnapshotStatusRestoring = SnapshotStatus("restoring") SnapshotStatusDeleting = SnapshotStatus("deleting") SnapshotStatusError = SnapshotStatus("error") SnapshotStatusLocked = SnapshotStatus("locked") )
const ( StorageClassUnknownStorageClass = StorageClass("unknown_storage_class") StorageClassLssd = StorageClass("lssd") StorageClassBssd = StorageClass("bssd") StorageClassSbs = StorageClass("sbs") )
const ( VolumeTypeLssd = VolumeType("lssd") VolumeTypeBssd = VolumeType("bssd") VolumeTypeSbs5k = VolumeType("sbs_5k") VolumeTypeSbs15k = VolumeType("sbs_15k") )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ACLRule ¶
type ACLRule struct { IP scw.IPNet `json:"ip"` // Deprecated Port *uint32 `json:"port,omitempty"` // Protocol: default value: tcp Protocol ACLRuleProtocol `json:"protocol"` // Direction: default value: inbound Direction ACLRuleDirection `json:"direction"` // Action: default value: allow Action ACLRuleAction `json:"action"` Description string `json:"description"` }
ACLRule: acl rule.
type ACLRuleAction ¶
type ACLRuleAction string
func (ACLRuleAction) MarshalJSON ¶
func (enum ACLRuleAction) MarshalJSON() ([]byte, error)
func (ACLRuleAction) String ¶
func (enum ACLRuleAction) String() string
func (*ACLRuleAction) UnmarshalJSON ¶
func (enum *ACLRuleAction) UnmarshalJSON(data []byte) error
func (ACLRuleAction) Values ¶
func (enum ACLRuleAction) Values() []ACLRuleAction
type ACLRuleDirection ¶
type ACLRuleDirection string
func (ACLRuleDirection) MarshalJSON ¶
func (enum ACLRuleDirection) MarshalJSON() ([]byte, error)
func (ACLRuleDirection) String ¶
func (enum ACLRuleDirection) String() string
func (*ACLRuleDirection) UnmarshalJSON ¶
func (enum *ACLRuleDirection) UnmarshalJSON(data []byte) error
func (ACLRuleDirection) Values ¶
func (enum ACLRuleDirection) Values() []ACLRuleDirection
type ACLRuleProtocol ¶
type ACLRuleProtocol string
func (ACLRuleProtocol) MarshalJSON ¶
func (enum ACLRuleProtocol) MarshalJSON() ([]byte, error)
func (ACLRuleProtocol) String ¶
func (enum ACLRuleProtocol) String() string
func (*ACLRuleProtocol) UnmarshalJSON ¶
func (enum *ACLRuleProtocol) UnmarshalJSON(data []byte) error
func (ACLRuleProtocol) Values ¶
func (enum ACLRuleProtocol) Values() []ACLRuleProtocol
type ACLRuleRequest ¶
ACLRuleRequest: acl rule request.
type API ¶
type API struct {
// contains filtered or unexported fields
}
This API allows you to manage your Managed Databases for PostgreSQL and MySQL.
func (*API) AddInstanceACLRules ¶
func (s *API) AddInstanceACLRules(req *AddInstanceACLRulesRequest, opts ...scw.RequestOption) (*AddInstanceACLRulesResponse, error)
AddInstanceACLRules: Add an additional ACL rule to a Database Instance.
func (*API) AddInstanceSettings ¶
func (s *API) AddInstanceSettings(req *AddInstanceSettingsRequest, opts ...scw.RequestOption) (*AddInstanceSettingsResponse, error)
AddInstanceSettings: Add an advanced setting to a Database Instance. You must set the `name` and the `value` of each setting.
func (*API) ApplyInstanceMaintenance ¶
func (s *API) ApplyInstanceMaintenance(req *ApplyInstanceMaintenanceRequest, opts ...scw.RequestOption) (*Maintenance, error)
ApplyInstanceMaintenance: Apply maintenance tasks to your Database Instance. This will trigger pending maintenance tasks to start in your Database Instance and can generate service interruption. Maintenance tasks can be applied between `starts_at` and `stops_at` times, and are run directly by Scaleway at `forced_at` timestamp.
func (*API) CloneInstance ¶
func (s *API) CloneInstance(req *CloneInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
CloneInstance: Clone a given Database Instance, specified by the `region` and `instance_id` parameters. The clone feature allows you to create a new Database Instance from an existing one. The clone includes all existing databases, users and permissions. You can create a clone on a Database Instance bigger than your current one.
func (*API) CreateDatabase ¶
func (s *API) CreateDatabase(req *CreateDatabaseRequest, opts ...scw.RequestOption) (*Database, error)
CreateDatabase: Create a new database. You must define the `name` parameter in the request.
func (*API) CreateDatabaseBackup ¶
func (s *API) CreateDatabaseBackup(req *CreateDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
CreateDatabaseBackup: Create a new backup. You must set the `instance_id`, `database_name`, `name` and `expires_at` parameters.
func (*API) CreateEndpoint ¶
func (s *API) CreateEndpoint(req *CreateEndpointRequest, opts ...scw.RequestOption) (*Endpoint, error)
CreateEndpoint: Create a new endpoint for a Database Instance. You can add `load_balancer` and `private_network` specifications to the body of the request.
func (*API) CreateInstance ¶
func (s *API) CreateInstance(req *CreateInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
CreateInstance: Create a new Database Instance. You must set the `engine`, `user_name`, `password` and `node_type` parameters. Optionally, you can specify the volume type and size.
func (*API) CreateInstanceFromSnapshot ¶
func (s *API) CreateInstanceFromSnapshot(req *CreateInstanceFromSnapshotRequest, opts ...scw.RequestOption) (*Instance, error)
CreateInstanceFromSnapshot: Restore a snapshot. When you restore a snapshot, a new Instance is created and billed to your account. Note that is possible to select a larger node type for your new Database Instance. However, the Block volume size will be the same as the size of the restored snapshot. All Instance settings will be restored if you chose a node type with the same or more memory size than the initial Instance. Settings will be reset to the default if your node type has less memory.
func (*API) CreateReadReplica ¶
func (s *API) CreateReadReplica(req *CreateReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
CreateReadReplica: Create a new Read Replica of a Database Instance. You must specify the `region` and the `instance_id`. You can only create a maximum of 3 Read Replicas per Database Instance.
func (*API) CreateReadReplicaEndpoint ¶
func (s *API) CreateReadReplicaEndpoint(req *CreateReadReplicaEndpointRequest, opts ...scw.RequestOption) (*ReadReplica, error)
CreateReadReplicaEndpoint: Create a new endpoint for a Read Replica. Read Replicas can have at most one direct access and one Private Network endpoint.
func (*API) CreateSnapshot ¶
func (s *API) CreateSnapshot(req *CreateSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
CreateSnapshot: Create a new snapshot of a Database Instance. You must define the `name` parameter in the request.
func (*API) CreateUser ¶
func (s *API) CreateUser(req *CreateUserRequest, opts ...scw.RequestOption) (*User, error)
CreateUser: Create a new user for a Database Instance. You must define the `name`, `password` and `is_admin` parameters.
func (*API) DeleteDatabase ¶
func (s *API) DeleteDatabase(req *DeleteDatabaseRequest, opts ...scw.RequestOption) error
DeleteDatabase: Delete a given database on a Database Instance. You must specify, in the endpoint, the `region`, `instance_id` and `name` parameters of the database you want to delete.
func (*API) DeleteDatabaseBackup ¶
func (s *API) DeleteDatabaseBackup(req *DeleteDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
DeleteDatabaseBackup: Delete a backup, specified by its database backup ID and region. Deleting a backup is permanent, and cannot be undone.
func (*API) DeleteEndpoint ¶
func (s *API) DeleteEndpoint(req *DeleteEndpointRequest, opts ...scw.RequestOption) error
DeleteEndpoint: Delete the endpoint of a Database Instance. You must specify the `region` and `endpoint_id` parameters of the endpoint you want to delete. Note that might need to update any environment configurations that point to the deleted endpoint.
func (*API) DeleteInstance ¶
func (s *API) DeleteInstance(req *DeleteInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
DeleteInstance: Delete a given Database Instance, specified by the `region` and `instance_id` parameters. Deleting a Database Instance is permanent, and cannot be undone. Note that upon deletion all your data will be lost.
func (*API) DeleteInstanceACLRules ¶
func (s *API) DeleteInstanceACLRules(req *DeleteInstanceACLRulesRequest, opts ...scw.RequestOption) (*DeleteInstanceACLRulesResponse, error)
DeleteInstanceACLRules: Delete one or more ACL rules of a Database Instance.
func (*API) DeleteInstanceSettings ¶
func (s *API) DeleteInstanceSettings(req *DeleteInstanceSettingsRequest, opts ...scw.RequestOption) (*DeleteInstanceSettingsResponse, error)
DeleteInstanceSettings: Delete an advanced setting in a Database Instance. You must specify the names of the settings you want to delete in the request.
func (*API) DeleteReadReplica ¶
func (s *API) DeleteReadReplica(req *DeleteReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
DeleteReadReplica: Delete a Read Replica of a Database Instance. You must specify the `region` and `read_replica_id` parameters of the Read Replica you want to delete.
func (*API) DeleteSnapshot ¶
func (s *API) DeleteSnapshot(req *DeleteSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
DeleteSnapshot: Delete a given snapshot of a Database Instance. You must specify, in the endpoint, the `region` and `snapshot_id` parameters of the snapshot you want to delete.
func (*API) DeleteUser ¶
func (s *API) DeleteUser(req *DeleteUserRequest, opts ...scw.RequestOption) error
DeleteUser: Delete a given user on a Database Instance. You must specify, in the endpoint, the `region`, `instance_id` and `name` parameters of the user you want to delete.
func (*API) ExportDatabaseBackup ¶
func (s *API) ExportDatabaseBackup(req *ExportDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
ExportDatabaseBackup: Export a backup, specified by the `database_backup_id` and the `region` parameters. The download URL is returned in the response.
func (*API) GetDatabaseBackup ¶
func (s *API) GetDatabaseBackup(req *GetDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
GetDatabaseBackup: Retrieve information about a given backup, specified by its database backup ID and region. Full details about the backup, like size, URL and expiration date, are returned in the response.
func (*API) GetEndpoint ¶
func (s *API) GetEndpoint(req *GetEndpointRequest, opts ...scw.RequestOption) (*Endpoint, error)
GetEndpoint: Retrieve information about a Database Instance endpoint. Full details about the endpoint, like `ip`, `port`, `private_network` and `load_balancer` specifications are returned in the response.
func (*API) GetInstance ¶
func (s *API) GetInstance(req *GetInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
GetInstance: Retrieve information about a given Database Instance, specified by the `region` and `instance_id` parameters. Its full details, including name, status, IP address and port, are returned in the response object.
func (*API) GetInstanceCertificate ¶
func (s *API) GetInstanceCertificate(req *GetInstanceCertificateRequest, opts ...scw.RequestOption) (*scw.File, error)
GetInstanceCertificate: Retrieve information about the TLS certificate of a given Database Instance. Details like name and content are returned in the response.
func (*API) GetInstanceLog ¶
func (s *API) GetInstanceLog(req *GetInstanceLogRequest, opts ...scw.RequestOption) (*InstanceLog, error)
GetInstanceLog: Retrieve information about the logs of a Database Instance. Specify the `instance_log_id` and `region` in your request to get information such as `download_url`, `status`, `expires_at` and `created_at` about your logs in the response.
func (*API) GetInstanceMetrics ¶
func (s *API) GetInstanceMetrics(req *GetInstanceMetricsRequest, opts ...scw.RequestOption) (*InstanceMetrics, error)
GetInstanceMetrics: Retrieve the time series metrics of a given Database Instance. You can define the period from which to retrieve metrics by specifying the `start_date` and `end_date`.
func (*API) GetReadReplica ¶
func (s *API) GetReadReplica(req *GetReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
GetReadReplica: Retrieve information about a Database Instance Read Replica. Full details about the Read Replica, like `endpoints`, `status` and `region` are returned in the response.
func (*API) GetSnapshot ¶
func (s *API) GetSnapshot(req *GetSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
GetSnapshot: Retrieve information about a given snapshot, specified by its `snapshot_id` and `region`. Full details about the snapshot, like size and expiration date, are returned in the response.
func (*API) ListDatabaseBackups ¶
func (s *API) ListDatabaseBackups(req *ListDatabaseBackupsRequest, opts ...scw.RequestOption) (*ListDatabaseBackupsResponse, error)
ListDatabaseBackups: List all backups in a specified region, for a given Scaleway Organization or Scaleway Project. By default, the backups listed are ordered by creation date in ascending order. This can be modified via the `order_by` field.
func (*API) ListDatabaseEngines ¶
func (s *API) ListDatabaseEngines(req *ListDatabaseEnginesRequest, opts ...scw.RequestOption) (*ListDatabaseEnginesResponse, error)
ListDatabaseEngines: List the PostgreSQL and MySQL database engines available at Scaleway.
func (*API) ListDatabases ¶
func (s *API) ListDatabases(req *ListDatabasesRequest, opts ...scw.RequestOption) (*ListDatabasesResponse, error)
ListDatabases: List all databases of a given Database Instance. By default, the databases returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. You can define additional parameters for your query, such as `name`, `managed` and `owner`.
func (*API) ListInstanceACLRules ¶
func (s *API) ListInstanceACLRules(req *ListInstanceACLRulesRequest, opts ...scw.RequestOption) (*ListInstanceACLRulesResponse, error)
ListInstanceACLRules: List the ACL rules for a given Database Instance. The response is an array of ACL objects, each one representing an ACL that denies, allows or redirects traffic based on certain conditions.
func (*API) ListInstanceLogs ¶
func (s *API) ListInstanceLogs(req *ListInstanceLogsRequest, opts ...scw.RequestOption) (*ListInstanceLogsResponse, error)
ListInstanceLogs: List the available logs of a Database Instance. By default, the logs returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field.
func (*API) ListInstanceLogsDetails ¶
func (s *API) ListInstanceLogsDetails(req *ListInstanceLogsDetailsRequest, opts ...scw.RequestOption) (*ListInstanceLogsDetailsResponse, error)
ListInstanceLogsDetails: List remote log details. By default, the details returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field.
func (*API) ListInstances ¶
func (s *API) ListInstances(req *ListInstancesRequest, opts ...scw.RequestOption) (*ListInstancesResponse, error)
ListInstances: List all Database Instances in the specified region, for a given Scaleway Organization or Scaleway Project. By default, the Database Instances returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. You can define additional parameters for your query, such as `tags` and `name`. For the `name` parameter, the value you include will be checked against the whole name string to see if it includes the string you put in the parameter.
func (*API) ListNodeTypes ¶
func (s *API) ListNodeTypes(req *ListNodeTypesRequest, opts ...scw.RequestOption) (*ListNodeTypesResponse, error)
ListNodeTypes: List all available node types. By default, the node types returned in the list are ordered by creation date in ascending order, though this can be modified via the `order_by` field.
func (*API) ListPrivileges ¶
func (s *API) ListPrivileges(req *ListPrivilegesRequest, opts ...scw.RequestOption) (*ListPrivilegesResponse, error)
ListPrivileges: List privileges of a user on a database. By default, the details returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. You can define additional parameters for your query, such as `database_name` and `user_name`.
func (*API) ListSnapshots ¶
func (s *API) ListSnapshots(req *ListSnapshotsRequest, opts ...scw.RequestOption) (*ListSnapshotsResponse, error)
ListSnapshots: List snapshots. You can include the `instance_id` or `project_id` in your query to get the list of snapshots for specific Database Instances and/or Projects. By default, the details returned in the list are ordered by creation date in ascending order, though this can be modified via the `order_by` field.
func (*API) ListUsers ¶
func (s *API) ListUsers(req *ListUsersRequest, opts ...scw.RequestOption) (*ListUsersResponse, error)
ListUsers: List all users of a given Database Instance. By default, the users returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field.
func (*API) MigrateEndpoint ¶
func (s *API) MigrateEndpoint(req *MigrateEndpointRequest, opts ...scw.RequestOption) (*Endpoint, error)
MigrateEndpoint: Migrate an existing instance endpoint to another instance.
func (*API) PrepareInstanceLogs ¶
func (s *API) PrepareInstanceLogs(req *PrepareInstanceLogsRequest, opts ...scw.RequestOption) (*PrepareInstanceLogsResponse, error)
PrepareInstanceLogs: Prepare your Database Instance logs. You can define the `start_date` and `end_date` parameters for your query. The download URL is returned in the response. Logs are recorded from 00h00 to 23h59 and then aggregated in a `.log` file once a day. Therefore, even if you specify a timeframe from which you want to get the logs, you will receive logs from the full 24 hours.
func (*API) PromoteReadReplica ¶
func (s *API) PromoteReadReplica(req *PromoteReadReplicaRequest, opts ...scw.RequestOption) (*Instance, error)
PromoteReadReplica: Promote a Read Replica to Database Instance automatically.
func (*API) PurgeInstanceLogs ¶
func (s *API) PurgeInstanceLogs(req *PurgeInstanceLogsRequest, opts ...scw.RequestOption) error
PurgeInstanceLogs: Purge a given remote log from a Database Instance. You can specify the `log_name` of the log you wish to clean from your Database Instance.
func (*API) RenewInstanceCertificate ¶
func (s *API) RenewInstanceCertificate(req *RenewInstanceCertificateRequest, opts ...scw.RequestOption) error
RenewInstanceCertificate: Renew a TLS for a Database Instance. Renewing a certificate means that you will not be able to connect to your Database Instance using the previous certificate. You will also need to download and update the new certificate for all database clients.
func (*API) ResetReadReplica ¶
func (s *API) ResetReadReplica(req *ResetReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
ResetReadReplica: When you resync a Read Replica, first it is reset, then its data is resynchronized from the primary node. Your Read Replica remains unavailable during the resync process. The duration of this process is proportional to the size of your Database Instance. The configured endpoints do not change.
func (*API) RestartInstance ¶
func (s *API) RestartInstance(req *RestartInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
RestartInstance: Restart a given Database Instance, specified by the `region` and `instance_id` parameters. The status of the Database Instance returned in the response.
func (*API) RestoreDatabaseBackup ¶
func (s *API) RestoreDatabaseBackup(req *RestoreDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
RestoreDatabaseBackup: Launch the process of restoring database backup. You must specify the `instance_id` of the Database Instance of destination, where the backup will be restored. Note that large database backups can take up to several hours to restore.
func (*API) SetInstanceACLRules ¶
func (s *API) SetInstanceACLRules(req *SetInstanceACLRulesRequest, opts ...scw.RequestOption) (*SetInstanceACLRulesResponse, error)
SetInstanceACLRules: Replace all the ACL rules of a Database Instance.
func (*API) SetInstanceSettings ¶
func (s *API) SetInstanceSettings(req *SetInstanceSettingsRequest, opts ...scw.RequestOption) (*SetInstanceSettingsResponse, error)
SetInstanceSettings: Update an advanced setting for a Database Instance. Settings added upon database engine initalization can only be defined once, and cannot, therefore, be updated.
func (*API) SetPrivilege ¶
func (s *API) SetPrivilege(req *SetPrivilegeRequest, opts ...scw.RequestOption) (*Privilege, error)
SetPrivilege: Set the privileges of a user on a database. You must define `database_name`, `user_name` and `permission` in the request body.
func (*API) UpdateDatabaseBackup ¶
func (s *API) UpdateDatabaseBackup(req *UpdateDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
UpdateDatabaseBackup: Update the parameters of a backup, including name and expiration date.
func (*API) UpdateInstance ¶
func (s *API) UpdateInstance(req *UpdateInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
UpdateInstance: Update the parameters of a Database Instance, including name, tags and backup schedule details.
func (*API) UpdateSnapshot ¶
func (s *API) UpdateSnapshot(req *UpdateSnapshotRequest, opts ...scw.RequestOption) (*Snapshot, error)
UpdateSnapshot: Update the parameters of a snapshot of a Database Instance. You can update the `name` and `expires_at` parameters.
func (*API) UpdateUser ¶
func (s *API) UpdateUser(req *UpdateUserRequest, opts ...scw.RequestOption) (*User, error)
UpdateUser: Update the parameters of a user on a Database Instance. You can update the `password` and `is_admin` parameters, but you cannot change the name of the user.
func (*API) UpgradeInstance ¶
func (s *API) UpgradeInstance(req *UpgradeInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
UpgradeInstance: Upgrade your current Database Instance specifications like node type, high availability, volume, or the database engine version. Note that upon upgrade the `enable_ha` parameter can only be set to `true`.
func (*API) WaitForDatabaseBackup ¶
func (s *API) WaitForDatabaseBackup(req *WaitForDatabaseBackupRequest, opts ...scw.RequestOption) (*DatabaseBackup, error)
WaitForDatabaseBackup waits for the backup to be in a "terminal state" before returning. This function can be used to wait for a backup to be ready for example.
func (*API) WaitForInstance ¶
func (s *API) WaitForInstance(req *WaitForInstanceRequest, opts ...scw.RequestOption) (*Instance, error)
WaitForInstance waits for the instance to be in a "terminal state" before returning. This function can be used to wait for an instance to be ready for example.
func (*API) WaitForInstanceLog ¶
func (s *API) WaitForInstanceLog(req *WaitForInstanceLogRequest, opts ...scw.RequestOption) (*InstanceLog, error)
WaitForInstanceLog waits for the instance logs to be in a "terminal state" before returning. This function can be used to wait for an instance logs to be ready for example.
func (*API) WaitForReadReplica ¶
func (s *API) WaitForReadReplica(req *WaitForReadReplicaRequest, opts ...scw.RequestOption) (*ReadReplica, error)
WaitForReadReplica waits for the read replica to be in a "terminal state" before returning. This function can be used to wait for a read replica to be ready for example.
type AddInstanceACLRulesRequest ¶
type AddInstanceACLRulesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to add ACL rules to. InstanceID string `json:"-"` // Rules: ACL rules to add to the Database Instance. Rules []*ACLRuleRequest `json:"rules"` }
AddInstanceACLRulesRequest: add instance acl rules request.
type AddInstanceACLRulesResponse ¶
type AddInstanceACLRulesResponse struct { // Rules: ACL Rules enabled for the Database Instance. Rules []*ACLRule `json:"rules"` }
AddInstanceACLRulesResponse: add instance acl rules response.
type AddInstanceSettingsRequest ¶
type AddInstanceSettingsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to add settings to. InstanceID string `json:"-"` // Settings: settings to add to the Database Instance. Settings []*InstanceSetting `json:"settings"` }
AddInstanceSettingsRequest: add instance settings request.
type AddInstanceSettingsResponse ¶
type AddInstanceSettingsResponse struct { // Settings: settings available on the Database Instance. Settings []*InstanceSetting `json:"settings"` }
AddInstanceSettingsResponse: add instance settings response.
type ApplyInstanceMaintenanceRequest ¶
type ApplyInstanceMaintenanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to apply maintenance. InstanceID string `json:"-"` }
ApplyInstanceMaintenanceRequest: apply instance maintenance request.
type BackupSchedule ¶
type BackupSchedule struct { // Frequency: frequency of the backup schedule (in hours). Frequency uint32 `json:"frequency"` // Retention: default retention period of backups (in days). Retention uint32 `json:"retention"` // Disabled: defines whether the backup schedule feature is disabled. Disabled bool `json:"disabled"` // NextRunAt: next run of the backup schedule (accurate to 10 minutes). NextRunAt *time.Time `json:"next_run_at"` }
BackupSchedule: backup schedule.
type CloneInstanceRequest ¶
type CloneInstanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to clone. InstanceID string `json:"-"` // Name: name of the Database Instance clone. Name string `json:"name"` // NodeType: node type of the clone. NodeType *string `json:"node_type,omitempty"` }
CloneInstanceRequest: clone instance request.
type CreateDatabaseBackupRequest ¶
type CreateDatabaseBackupRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"instance_id"` // DatabaseName: name of the database you want to back up. DatabaseName string `json:"database_name"` // Name: name of the backup. Name string `json:"name"` // ExpiresAt: expiration date (must follow the ISO 8601 format). ExpiresAt *time.Time `json:"expires_at,omitempty"` }
CreateDatabaseBackupRequest: create database backup request.
type CreateDatabaseRequest ¶
type CreateDatabaseRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance where to create the database. InstanceID string `json:"-"` // Name: name of the database. Name string `json:"name"` }
CreateDatabaseRequest: create database request.
type CreateEndpointRequest ¶
type CreateEndpointRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you to which you want to add an endpoint. InstanceID string `json:"-"` // EndpointSpec: specification of the endpoint you want to create. EndpointSpec *EndpointSpec `json:"endpoint_spec,omitempty"` }
CreateEndpointRequest: create endpoint request.
type CreateInstanceFromSnapshotRequest ¶
type CreateInstanceFromSnapshotRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // SnapshotID: block snapshot of the Database Instance. SnapshotID string `json:"-"` // InstanceName: name of the Database Instance created with the snapshot. InstanceName string `json:"instance_name"` // IsHaCluster: defines whether or not High-Availability is enabled on the new Database Instance. IsHaCluster *bool `json:"is_ha_cluster,omitempty"` // NodeType: the node type used to restore the snapshot. NodeType *string `json:"node_type,omitempty"` }
CreateInstanceFromSnapshotRequest: create instance from snapshot request.
type CreateInstanceRequest ¶
type CreateInstanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // Deprecated: OrganizationID: please use project_id instead. // Precisely one of ProjectID, OrganizationID must be set. OrganizationID *string `json:"organization_id,omitempty"` // ProjectID: the Project ID on which the Database Instance will be created. // Precisely one of ProjectID, OrganizationID must be set. ProjectID *string `json:"project_id,omitempty"` // Name: name of the Database Instance. Name string `json:"name"` // Engine: database engine of the Database Instance (PostgreSQL, MySQL, ...). Engine string `json:"engine"` // UserName: username created when the Database Instance is created. UserName string `json:"user_name"` // Password: password of the user. Password string `json:"password"` // NodeType: type of node to use for the Database Instance. NodeType string `json:"node_type"` // IsHaCluster: defines whether or not High-Availability is enabled. IsHaCluster bool `json:"is_ha_cluster"` // DisableBackup: defines whether or not backups are disabled. DisableBackup bool `json:"disable_backup"` // Tags: tags to apply to the Database Instance. Tags []string `json:"tags"` // InitSettings: list of engine settings to be set upon Database Instance initialization. InitSettings []*InstanceSetting `json:"init_settings"` // VolumeType: type of volume where data is stored (lssd, bssd, ...). // Default value: lssd VolumeType VolumeType `json:"volume_type"` // VolumeSize: volume size when volume_type is not lssd. VolumeSize scw.Size `json:"volume_size"` // InitEndpoints: one or multiple EndpointSpec used to expose your Database Instance. A load_balancer public endpoint is systematically created. InitEndpoints []*EndpointSpec `json:"init_endpoints"` // BackupSameRegion: defines whether to or not to store logical backups in the same region as the Database Instance. BackupSameRegion bool `json:"backup_same_region"` // Encryption: encryption at rest settings for your Database Instance. Encryption *EncryptionAtRest `json:"encryption,omitempty"` }
CreateInstanceRequest: create instance request.
type CreateReadReplicaEndpointRequest ¶
type CreateReadReplicaEndpointRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // ReadReplicaID: UUID of the Read Replica. ReadReplicaID string `json:"-"` // EndpointSpec: specification of the endpoint you want to create. EndpointSpec []*ReadReplicaEndpointSpec `json:"endpoint_spec"` }
CreateReadReplicaEndpointRequest: create read replica endpoint request.
type CreateReadReplicaRequest ¶
type CreateReadReplicaRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to create a Read Replica from. InstanceID string `json:"instance_id"` // EndpointSpec: specification of the endpoint you want to create. EndpointSpec []*ReadReplicaEndpointSpec `json:"endpoint_spec"` // SameZone: defines whether to create the replica in the same availability zone as the main instance nodes or not. SameZone *bool `json:"same_zone,omitempty"` }
CreateReadReplicaRequest: create read replica request.
type CreateSnapshotRequest ¶
type CreateSnapshotRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` // Name: name of the snapshot. Name string `json:"name"` // ExpiresAt: expiration date (must follow the ISO 8601 format). ExpiresAt *time.Time `json:"expires_at,omitempty"` }
CreateSnapshotRequest: create snapshot request.
type CreateUserRequest ¶
type CreateUserRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance in which you want to create a user. InstanceID string `json:"-"` // Name: name of the user you want to create. Name string `json:"name"` // Password: password of the user you want to create. Password string `json:"password"` // IsAdmin: defines whether the user will have administrative privileges. IsAdmin bool `json:"is_admin"` }
CreateUserRequest: create user request.
type Database ¶
type Database struct { // Name: name of the database. Name string `json:"name"` // Owner: name of the database owner. Owner string `json:"owner"` // Managed: defines whether the database is managed or not. Managed bool `json:"managed"` // Size: size of the database. Size scw.Size `json:"size"` }
Database: database.
type DatabaseBackup ¶
type DatabaseBackup struct { // ID: UUID of the database backup. ID string `json:"id"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"instance_id"` // DatabaseName: name of backed up database. DatabaseName string `json:"database_name"` // Name: name of the backup. Name string `json:"name"` // Status: status of the backup. // Default value: unknown Status DatabaseBackupStatus `json:"status"` // Size: size of the database backup. Size *scw.Size `json:"size"` // ExpiresAt: expiration date (must follow the ISO 8601 format). ExpiresAt *time.Time `json:"expires_at"` // CreatedAt: creation date (must follow the ISO 8601 format). CreatedAt *time.Time `json:"created_at"` // UpdatedAt: updated date (must follow the ISO 8601 format). UpdatedAt *time.Time `json:"updated_at"` // InstanceName: name of the Database Instance of the backup. InstanceName string `json:"instance_name"` // DownloadURL: URL you can download the backup from. DownloadURL *string `json:"download_url"` // DownloadURLExpiresAt: expiration date of the download link. DownloadURLExpiresAt *time.Time `json:"download_url_expires_at"` // Region: region of the database backup. Region scw.Region `json:"region"` // SameRegion: store logical backups in the same region as the source Database Instance. SameRegion bool `json:"same_region"` }
DatabaseBackup: database backup.
type DatabaseBackupStatus ¶
type DatabaseBackupStatus string
func (DatabaseBackupStatus) MarshalJSON ¶
func (enum DatabaseBackupStatus) MarshalJSON() ([]byte, error)
func (DatabaseBackupStatus) String ¶
func (enum DatabaseBackupStatus) String() string
func (*DatabaseBackupStatus) UnmarshalJSON ¶
func (enum *DatabaseBackupStatus) UnmarshalJSON(data []byte) error
func (DatabaseBackupStatus) Values ¶
func (enum DatabaseBackupStatus) Values() []DatabaseBackupStatus
type DatabaseEngine ¶
type DatabaseEngine struct { // Name: engine name. Name string `json:"name"` // LogoURL: engine logo URL. LogoURL string `json:"logo_url"` // Versions: available versions. Versions []*EngineVersion `json:"versions"` // Region: region of this Database Instance. Region scw.Region `json:"region"` }
DatabaseEngine: database engine.
type DeleteDatabaseBackupRequest ¶
type DeleteDatabaseBackupRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // DatabaseBackupID: UUID of the database backup to delete. DatabaseBackupID string `json:"-"` }
DeleteDatabaseBackupRequest: delete database backup request.
type DeleteDatabaseRequest ¶
type DeleteDatabaseRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance where to delete the database. InstanceID string `json:"-"` // Name: name of the database to delete. Name string `json:"-"` }
DeleteDatabaseRequest: delete database request.
type DeleteEndpointRequest ¶
type DeleteEndpointRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // EndpointID: this endpoint can also be used to delete a Read Replica endpoint. EndpointID string `json:"-"` }
DeleteEndpointRequest: delete endpoint request.
type DeleteInstanceACLRulesRequest ¶
type DeleteInstanceACLRulesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to delete an ACL rule from. InstanceID string `json:"-"` // ACLRuleIPs: IP addresses defined in the ACL rules of the Database Instance. ACLRuleIPs []string `json:"acl_rule_ips"` }
DeleteInstanceACLRulesRequest: delete instance acl rules request.
type DeleteInstanceACLRulesResponse ¶
type DeleteInstanceACLRulesResponse struct { // Rules: IP addresses defined in the ACL rules of the Database Instance. Rules []*ACLRule `json:"rules"` }
DeleteInstanceACLRulesResponse: delete instance acl rules response.
type DeleteInstanceRequest ¶
type DeleteInstanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance to delete. InstanceID string `json:"-"` }
DeleteInstanceRequest: delete instance request.
type DeleteInstanceSettingsRequest ¶
type DeleteInstanceSettingsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance to delete settings from. InstanceID string `json:"-"` // SettingNames: settings names to delete. SettingNames []string `json:"setting_names"` }
DeleteInstanceSettingsRequest: delete instance settings request.
type DeleteInstanceSettingsResponse ¶
type DeleteInstanceSettingsResponse struct { // Settings: settings names to delete from the Database Instance. Settings []*InstanceSetting `json:"settings"` }
DeleteInstanceSettingsResponse: delete instance settings response.
type DeleteReadReplicaRequest ¶
type DeleteReadReplicaRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // ReadReplicaID: UUID of the Read Replica. ReadReplicaID string `json:"-"` }
DeleteReadReplicaRequest: delete read replica request.
type DeleteSnapshotRequest ¶
type DeleteSnapshotRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // SnapshotID: UUID of the snapshot to delete. SnapshotID string `json:"-"` }
DeleteSnapshotRequest: delete snapshot request.
type DeleteUserRequest ¶
type DeleteUserRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance to delete the user from. InstanceID string `json:"-"` // Name: name of the user. Name string `json:"-"` }
DeleteUserRequest: delete user request.
type EncryptionAtRest ¶
type EncryptionAtRest struct {
Enabled bool `json:"enabled"`
}
EncryptionAtRest: encryption at rest.
type Endpoint ¶
type Endpoint struct { // ID: UUID of the endpoint. ID string `json:"id"` // IP: iPv4 address of the endpoint. // Precisely one of IP, Hostname must be set. IP *net.IP `json:"ip,omitempty"` // Port: TCP port of the endpoint. Port uint32 `json:"port"` // Name: name of the endpoint. Name *string `json:"name"` // PrivateNetwork: private Network details. One maximum per Database Instance or Read Replica (a Database Instance and its Read Replica can have different Private Networks). Cannot be updated (has to be deleted and recreated). // Precisely one of PrivateNetwork, LoadBalancer, DirectAccess must be set. PrivateNetwork *EndpointPrivateNetworkDetails `json:"private_network,omitempty"` // LoadBalancer: load balancer details. Public endpoint for Database Instance which is systematically present. One per Database Instance. // Precisely one of PrivateNetwork, LoadBalancer, DirectAccess must be set. LoadBalancer *EndpointLoadBalancerDetails `json:"load_balancer,omitempty"` // DirectAccess: direct access details. Public endpoint reserved for Read Replicas. One per Read Replica. // Precisely one of PrivateNetwork, LoadBalancer, DirectAccess must be set. DirectAccess *EndpointDirectAccessDetails `json:"direct_access,omitempty"` // Hostname: hostname of the endpoint. // Precisely one of IP, Hostname must be set. Hostname *string `json:"hostname,omitempty"` }
Endpoint: endpoint.
type EndpointDirectAccessDetails ¶
type EndpointDirectAccessDetails struct { }
EndpointDirectAccessDetails: endpoint direct access details.
type EndpointLoadBalancerDetails ¶
type EndpointLoadBalancerDetails struct { }
EndpointLoadBalancerDetails: endpoint load balancer details.
type EndpointPrivateNetworkDetails ¶
type EndpointPrivateNetworkDetails struct { // PrivateNetworkID: UUID of the private network. PrivateNetworkID string `json:"private_network_id"` // ServiceIP: cIDR notation of the endpoint IPv4 address. ServiceIP scw.IPNet `json:"service_ip"` // Zone: private network zone. Zone scw.Zone `json:"zone"` // ProvisioningMode: how endpoint ips are provisioned. // Default value: static ProvisioningMode EndpointPrivateNetworkDetailsProvisioningMode `json:"provisioning_mode"` }
EndpointPrivateNetworkDetails: endpoint private network details.
type EndpointPrivateNetworkDetailsProvisioningMode ¶
type EndpointPrivateNetworkDetailsProvisioningMode string
func (EndpointPrivateNetworkDetailsProvisioningMode) MarshalJSON ¶
func (enum EndpointPrivateNetworkDetailsProvisioningMode) MarshalJSON() ([]byte, error)
func (EndpointPrivateNetworkDetailsProvisioningMode) String ¶
func (enum EndpointPrivateNetworkDetailsProvisioningMode) String() string
func (*EndpointPrivateNetworkDetailsProvisioningMode) UnmarshalJSON ¶
func (enum *EndpointPrivateNetworkDetailsProvisioningMode) UnmarshalJSON(data []byte) error
func (EndpointPrivateNetworkDetailsProvisioningMode) Values ¶
func (enum EndpointPrivateNetworkDetailsProvisioningMode) Values() []EndpointPrivateNetworkDetailsProvisioningMode
type EndpointSpec ¶
type EndpointSpec struct { // LoadBalancer: load balancer endpoint specifications. Public endpoint for Database Instance which is systematically present. One per RDB instance. // Precisely one of LoadBalancer, PrivateNetwork must be set. LoadBalancer *EndpointSpecLoadBalancer `json:"load_balancer,omitempty"` // PrivateNetwork: private Network endpoint specifications. One maximum per Database Instance or Read Replica (a Database Instance and its Read Replica can have different Private Networks). Cannot be updated (has to be deleted and recreated). // Precisely one of LoadBalancer, PrivateNetwork must be set. PrivateNetwork *EndpointSpecPrivateNetwork `json:"private_network,omitempty"` }
EndpointSpec: endpoint spec.
type EndpointSpecLoadBalancer ¶
type EndpointSpecLoadBalancer struct { }
EndpointSpecLoadBalancer: endpoint spec load balancer.
type EndpointSpecPrivateNetwork ¶
type EndpointSpecPrivateNetwork struct { // PrivateNetworkID: UUID of the Private Network to be connected to the Database Instance. PrivateNetworkID string `json:"private_network_id"` // ServiceIP: endpoint IPv4 address with a CIDR notation. Refer to the official Scaleway documentation to learn more about IP and subnet limitations. // Precisely one of ServiceIP, IpamConfig must be set. ServiceIP *scw.IPNet `json:"service_ip,omitempty"` // IpamConfig: automated configuration of your Private Network endpoint with Scaleway IPAM service. One at the most per Database Instance or Read Replica (a Database Instance and its Read Replica can have different Private Networks). Cannot be updated (has to be deleted and recreated). // Precisely one of ServiceIP, IpamConfig must be set. IpamConfig *EndpointSpecPrivateNetworkIpamConfig `json:"ipam_config,omitempty"` }
EndpointSpecPrivateNetwork: endpoint spec private network.
type EndpointSpecPrivateNetworkIpamConfig ¶
type EndpointSpecPrivateNetworkIpamConfig struct { }
EndpointSpecPrivateNetworkIpamConfig: endpoint spec private network ipam config.
type EngineSetting ¶
type EngineSetting struct { // Name: setting name from the database engine. Name string `json:"name"` // DefaultValue: value set when not specified. DefaultValue string `json:"default_value"` // HotConfigurable: setting can be applied without restarting. HotConfigurable bool `json:"hot_configurable"` // Description: setting description. Description string `json:"description"` // PropertyType: setting type. // Default value: BOOLEAN PropertyType EngineSettingPropertyType `json:"property_type"` // Unit: setting base unit. Unit *string `json:"unit"` // StringConstraint: validation regex for string type settings. StringConstraint *string `json:"string_constraint"` // IntMin: minimum value for int types. IntMin *int32 `json:"int_min"` // IntMax: maximum value for int types. IntMax *int32 `json:"int_max"` // FloatMin: minimum value for float types. FloatMin *float32 `json:"float_min"` // FloatMax: maximum value for float types. FloatMax *float32 `json:"float_max"` }
EngineSetting: engine setting.
type EngineSettingPropertyType ¶
type EngineSettingPropertyType string
func (EngineSettingPropertyType) MarshalJSON ¶
func (enum EngineSettingPropertyType) MarshalJSON() ([]byte, error)
func (EngineSettingPropertyType) String ¶
func (enum EngineSettingPropertyType) String() string
func (*EngineSettingPropertyType) UnmarshalJSON ¶
func (enum *EngineSettingPropertyType) UnmarshalJSON(data []byte) error
func (EngineSettingPropertyType) Values ¶
func (enum EngineSettingPropertyType) Values() []EngineSettingPropertyType
type EngineVersion ¶
type EngineVersion struct { // Version: database engine version. Version string `json:"version"` // Name: database engine name. Name string `json:"name"` // EndOfLife: end of life date. EndOfLife *time.Time `json:"end_of_life"` // AvailableSettings: engine settings available to be set. AvailableSettings []*EngineSetting `json:"available_settings"` // Disabled: disabled versions cannot be created. Disabled bool `json:"disabled"` // Beta: beta status of engine version. Beta bool `json:"beta"` // AvailableInitSettings: engine settings available to be set at database initialization. AvailableInitSettings []*EngineSetting `json:"available_init_settings"` }
EngineVersion: engine version.
type ExportDatabaseBackupRequest ¶
type ExportDatabaseBackupRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // DatabaseBackupID: UUID of the database backup you want to export. DatabaseBackupID string `json:"-"` }
ExportDatabaseBackupRequest: export database backup request.
type GetDatabaseBackupRequest ¶
type GetDatabaseBackupRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // DatabaseBackupID: UUID of the database backup. DatabaseBackupID string `json:"-"` }
GetDatabaseBackupRequest: get database backup request.
type GetEndpointRequest ¶
type GetEndpointRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // EndpointID: UUID of the endpoint you want to get. EndpointID string `json:"-"` }
GetEndpointRequest: get endpoint request.
type GetInstanceCertificateRequest ¶
type GetInstanceCertificateRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` }
GetInstanceCertificateRequest: get instance certificate request.
type GetInstanceLogRequest ¶
type GetInstanceLogRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceLogID: UUID of the instance_log you want. InstanceLogID string `json:"-"` }
GetInstanceLogRequest: get instance log request.
type GetInstanceMetricsRequest ¶
type GetInstanceMetricsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` // StartDate: start date to gather metrics from. StartDate *time.Time `json:"-"` // EndDate: end date to gather metrics from. EndDate *time.Time `json:"-"` // MetricName: name of the metric to gather. MetricName *string `json:"-"` }
GetInstanceMetricsRequest: get instance metrics request.
type GetInstanceRequest ¶
type GetInstanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` }
GetInstanceRequest: get instance request.
type GetReadReplicaRequest ¶
type GetReadReplicaRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // ReadReplicaID: UUID of the Read Replica. ReadReplicaID string `json:"-"` }
GetReadReplicaRequest: get read replica request.
type GetSnapshotRequest ¶
type GetSnapshotRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // SnapshotID: UUID of the snapshot. SnapshotID string `json:"-"` }
GetSnapshotRequest: get snapshot request.
type Instance ¶
type Instance struct { // CreatedAt: creation date (must follow the ISO 8601 format). CreatedAt *time.Time `json:"created_at"` // Volume: volumes of the Database Instance. Volume *Volume `json:"volume"` // Region: region the Database Instance is in. Region scw.Region `json:"region"` // ID: UUID of the Database Instance. ID string `json:"id"` // Name: name of the Database Instance. Name string `json:"name"` // OrganizationID: organization ID the Database Instance belongs to. OrganizationID string `json:"organization_id"` // ProjectID: project ID the Database Instance belongs to. ProjectID string `json:"project_id"` // Status: status of the Database Instance. // Default value: unknown Status InstanceStatus `json:"status"` // Engine: database engine of the database (PostgreSQL, MySQL, ...). Engine string `json:"engine"` // UpgradableVersion: available database engine versions for upgrade. UpgradableVersion []*UpgradableVersion `json:"upgradable_version"` // Deprecated: Endpoint: endpoint of the Database Instance. Endpoint *Endpoint `json:"endpoint,omitempty"` // Tags: list of tags applied to the Database Instance. Tags []string `json:"tags"` // Settings: advanced settings of the Database Instance. Settings []*InstanceSetting `json:"settings"` // BackupSchedule: backup schedule of the Database Instance. BackupSchedule *BackupSchedule `json:"backup_schedule"` // IsHaCluster: defines whether or not High-Availability is enabled. IsHaCluster bool `json:"is_ha_cluster"` // ReadReplicas: read Replicas of the Database Instance. ReadReplicas []*ReadReplica `json:"read_replicas"` // NodeType: node type of the Database Instance. NodeType string `json:"node_type"` // InitSettings: list of engine settings to be set at database initialization. InitSettings []*InstanceSetting `json:"init_settings"` // Endpoints: list of Database Instance endpoints. Endpoints []*Endpoint `json:"endpoints"` // LogsPolicy: logs policy of the Database Instance. LogsPolicy *LogsPolicy `json:"logs_policy"` // BackupSameRegion: store logical backups in the same region as the Database Instance. BackupSameRegion bool `json:"backup_same_region"` // Maintenances: list of Database Instance maintenance events. Maintenances []*Maintenance `json:"maintenances"` // Encryption: encryption at rest settings for your Database Instance. Encryption *EncryptionAtRest `json:"encryption"` }
Instance: instance.
type InstanceLog ¶
type InstanceLog struct { // DownloadURL: presigned S3 URL to download your log file. DownloadURL *string `json:"download_url"` // ID: UUID of the Database Instance log. ID string `json:"id"` // Status: status of the logs in a Database Instance. // Default value: unknown Status InstanceLogStatus `json:"status"` // NodeName: name of the underlying node. NodeName string `json:"node_name"` // ExpiresAt: expiration date (must follow the ISO 8601 format). ExpiresAt *time.Time `json:"expires_at"` // CreatedAt: creation date (must follow the ISO 8601 format). CreatedAt *time.Time `json:"created_at"` // Region: region the Database Instance is in. Region scw.Region `json:"region"` }
InstanceLog: instance log.
type InstanceLogStatus ¶
type InstanceLogStatus string
func (InstanceLogStatus) MarshalJSON ¶
func (enum InstanceLogStatus) MarshalJSON() ([]byte, error)
func (InstanceLogStatus) String ¶
func (enum InstanceLogStatus) String() string
func (*InstanceLogStatus) UnmarshalJSON ¶
func (enum *InstanceLogStatus) UnmarshalJSON(data []byte) error
func (InstanceLogStatus) Values ¶
func (enum InstanceLogStatus) Values() []InstanceLogStatus
type InstanceMetrics ¶
type InstanceMetrics struct { // Timeseries: time series of metrics of a Database Instance. Timeseries []*scw.TimeSeries `json:"timeseries"` }
InstanceMetrics: instance metrics.
type InstanceSetting ¶
InstanceSetting: instance setting.
type InstanceStatus ¶
type InstanceStatus string
func (InstanceStatus) MarshalJSON ¶
func (enum InstanceStatus) MarshalJSON() ([]byte, error)
func (InstanceStatus) String ¶
func (enum InstanceStatus) String() string
func (*InstanceStatus) UnmarshalJSON ¶
func (enum *InstanceStatus) UnmarshalJSON(data []byte) error
func (InstanceStatus) Values ¶
func (enum InstanceStatus) Values() []InstanceStatus
type ListDatabaseBackupsRequest ¶
type ListDatabaseBackupsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // Name: name of the database backups. Name *string `json:"-"` // OrderBy: criteria to use when ordering database backups listing. // Default value: created_at_asc OrderBy ListDatabaseBackupsRequestOrderBy `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID *string `json:"-"` // OrganizationID: organization ID of the Organization the database backups belong to. OrganizationID *string `json:"-"` // ProjectID: project ID of the Project the database backups belong to. ProjectID *string `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListDatabaseBackupsRequest: list database backups request.
type ListDatabaseBackupsRequestOrderBy ¶
type ListDatabaseBackupsRequestOrderBy string
func (ListDatabaseBackupsRequestOrderBy) MarshalJSON ¶
func (enum ListDatabaseBackupsRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListDatabaseBackupsRequestOrderBy) String ¶
func (enum ListDatabaseBackupsRequestOrderBy) String() string
func (*ListDatabaseBackupsRequestOrderBy) UnmarshalJSON ¶
func (enum *ListDatabaseBackupsRequestOrderBy) UnmarshalJSON(data []byte) error
func (ListDatabaseBackupsRequestOrderBy) Values ¶
func (enum ListDatabaseBackupsRequestOrderBy) Values() []ListDatabaseBackupsRequestOrderBy
type ListDatabaseBackupsResponse ¶
type ListDatabaseBackupsResponse struct { // DatabaseBackups: list of database backups. DatabaseBackups []*DatabaseBackup `json:"database_backups"` // TotalCount: total count of database backups available. TotalCount uint32 `json:"total_count"` }
ListDatabaseBackupsResponse: list database backups response.
func (*ListDatabaseBackupsResponse) UnsafeAppend ¶
func (r *ListDatabaseBackupsResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListDatabaseBackupsResponse) UnsafeGetTotalCount ¶
func (r *ListDatabaseBackupsResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListDatabaseEnginesRequest ¶
type ListDatabaseEnginesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // Name: name of the database engine. Name *string `json:"-"` // Version: version of the database engine. Version *string `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListDatabaseEnginesRequest: list database engines request.
type ListDatabaseEnginesResponse ¶
type ListDatabaseEnginesResponse struct { // Engines: list of the available database engines. Engines []*DatabaseEngine `json:"engines"` // TotalCount: total count of database engines available. TotalCount uint32 `json:"total_count"` }
ListDatabaseEnginesResponse: list database engines response.
func (*ListDatabaseEnginesResponse) UnsafeAppend ¶
func (r *ListDatabaseEnginesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListDatabaseEnginesResponse) UnsafeGetTotalCount ¶
func (r *ListDatabaseEnginesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListDatabasesRequest ¶
type ListDatabasesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance to list the databases of. InstanceID string `json:"-"` // Name: name of the database. Name *string `json:"-"` // Managed: defines whether or not the database is managed. Managed *bool `json:"-"` // Owner: user that owns this database. Owner *string `json:"-"` // OrderBy: criteria to use when ordering database listing. // Default value: name_asc OrderBy ListDatabasesRequestOrderBy `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListDatabasesRequest: list databases request.
type ListDatabasesRequestOrderBy ¶
type ListDatabasesRequestOrderBy string
func (ListDatabasesRequestOrderBy) MarshalJSON ¶
func (enum ListDatabasesRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListDatabasesRequestOrderBy) String ¶
func (enum ListDatabasesRequestOrderBy) String() string
func (*ListDatabasesRequestOrderBy) UnmarshalJSON ¶
func (enum *ListDatabasesRequestOrderBy) UnmarshalJSON(data []byte) error
func (ListDatabasesRequestOrderBy) Values ¶
func (enum ListDatabasesRequestOrderBy) Values() []ListDatabasesRequestOrderBy
type ListDatabasesResponse ¶
type ListDatabasesResponse struct { // Databases: list of the databases. Databases []*Database `json:"databases"` // TotalCount: total count of databases present on a Database Instance. TotalCount uint32 `json:"total_count"` }
ListDatabasesResponse: list databases response.
func (*ListDatabasesResponse) UnsafeAppend ¶
func (r *ListDatabasesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListDatabasesResponse) UnsafeGetTotalCount ¶
func (r *ListDatabasesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListInstanceACLRulesRequest ¶
type ListInstanceACLRulesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListInstanceACLRulesRequest: list instance acl rules request.
type ListInstanceACLRulesResponse ¶
type ListInstanceACLRulesResponse struct { // Rules: list of ACL rules present on a Database Instance. Rules []*ACLRule `json:"rules"` // TotalCount: total count of ACL rules present on a Database Instance. TotalCount uint32 `json:"total_count"` }
ListInstanceACLRulesResponse: list instance acl rules response.
func (*ListInstanceACLRulesResponse) UnsafeAppend ¶
func (r *ListInstanceACLRulesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListInstanceACLRulesResponse) UnsafeGetTotalCount ¶
func (r *ListInstanceACLRulesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListInstanceLogsDetailsRequest ¶
type ListInstanceLogsDetailsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want logs of. InstanceID string `json:"-"` }
ListInstanceLogsDetailsRequest: list instance logs details request.
type ListInstanceLogsDetailsResponse ¶
type ListInstanceLogsDetailsResponse struct { // Details: remote Database Instance logs details. Details []*ListInstanceLogsDetailsResponseInstanceLogDetail `json:"details"` }
ListInstanceLogsDetailsResponse: list instance logs details response.
type ListInstanceLogsDetailsResponseInstanceLogDetail ¶
type ListInstanceLogsDetailsResponseInstanceLogDetail struct { LogName string `json:"log_name"` Size uint64 `json:"size"` }
ListInstanceLogsDetailsResponseInstanceLogDetail: list instance logs details response instance log detail.
type ListInstanceLogsRequest ¶
type ListInstanceLogsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want logs of. InstanceID string `json:"-"` // OrderBy: criteria to use when ordering Database Instance logs listing. // Default value: created_at_asc OrderBy ListInstanceLogsRequestOrderBy `json:"order_by"` }
ListInstanceLogsRequest: list instance logs request.
type ListInstanceLogsRequestOrderBy ¶
type ListInstanceLogsRequestOrderBy string
func (ListInstanceLogsRequestOrderBy) MarshalJSON ¶
func (enum ListInstanceLogsRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListInstanceLogsRequestOrderBy) String ¶
func (enum ListInstanceLogsRequestOrderBy) String() string
func (*ListInstanceLogsRequestOrderBy) UnmarshalJSON ¶
func (enum *ListInstanceLogsRequestOrderBy) UnmarshalJSON(data []byte) error
func (ListInstanceLogsRequestOrderBy) Values ¶
func (enum ListInstanceLogsRequestOrderBy) Values() []ListInstanceLogsRequestOrderBy
type ListInstanceLogsResponse ¶
type ListInstanceLogsResponse struct { // InstanceLogs: available logs in a Database Instance. InstanceLogs []*InstanceLog `json:"instance_logs"` }
ListInstanceLogsResponse: list instance logs response.
type ListInstancesRequest ¶
type ListInstancesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // Tags: list Database Instances that have a given tag. Tags []string `json:"-"` // Name: lists Database Instances that match a name pattern. Name *string `json:"-"` // OrderBy: criteria to use when ordering Database Instance listings. // Default value: created_at_asc OrderBy ListInstancesRequestOrderBy `json:"-"` // OrganizationID: please use project_id instead. OrganizationID *string `json:"-"` // ProjectID: project ID to list the Database Instance of. ProjectID *string `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListInstancesRequest: list instances request.
type ListInstancesRequestOrderBy ¶
type ListInstancesRequestOrderBy string
func (ListInstancesRequestOrderBy) MarshalJSON ¶
func (enum ListInstancesRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListInstancesRequestOrderBy) String ¶
func (enum ListInstancesRequestOrderBy) String() string
func (*ListInstancesRequestOrderBy) UnmarshalJSON ¶
func (enum *ListInstancesRequestOrderBy) UnmarshalJSON(data []byte) error
func (ListInstancesRequestOrderBy) Values ¶
func (enum ListInstancesRequestOrderBy) Values() []ListInstancesRequestOrderBy
type ListInstancesResponse ¶
type ListInstancesResponse struct { // Instances: list of all Database Instances available in an Organization or Project. Instances []*Instance `json:"instances"` // TotalCount: total count of Database Instances available in a Organization or Project. TotalCount uint32 `json:"total_count"` }
ListInstancesResponse: list instances response.
func (*ListInstancesResponse) UnsafeAppend ¶
func (r *ListInstancesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListInstancesResponse) UnsafeGetTotalCount ¶
func (r *ListInstancesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListNodeTypesRequest ¶
type ListNodeTypesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // IncludeDisabledTypes: defines whether or not to include disabled types. IncludeDisabledTypes bool `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListNodeTypesRequest: list node types request.
type ListNodeTypesResponse ¶
type ListNodeTypesResponse struct { // NodeTypes: types of the node. NodeTypes []*NodeType `json:"node_types"` // TotalCount: total count of node-types available. TotalCount uint32 `json:"total_count"` }
ListNodeTypesResponse: list node types response.
func (*ListNodeTypesResponse) UnsafeAppend ¶
func (r *ListNodeTypesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListNodeTypesResponse) UnsafeGetTotalCount ¶
func (r *ListNodeTypesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListPrivilegesRequest ¶
type ListPrivilegesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` // OrderBy: criteria to use when ordering privileges listing. // Default value: user_name_asc OrderBy ListPrivilegesRequestOrderBy `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` // DatabaseName: name of the database. DatabaseName *string `json:"-"` // UserName: name of the user. UserName *string `json:"-"` }
ListPrivilegesRequest: list privileges request.
type ListPrivilegesRequestOrderBy ¶
type ListPrivilegesRequestOrderBy string
func (ListPrivilegesRequestOrderBy) MarshalJSON ¶
func (enum ListPrivilegesRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListPrivilegesRequestOrderBy) String ¶
func (enum ListPrivilegesRequestOrderBy) String() string
func (*ListPrivilegesRequestOrderBy) UnmarshalJSON ¶
func (enum *ListPrivilegesRequestOrderBy) UnmarshalJSON(data []byte) error
func (ListPrivilegesRequestOrderBy) Values ¶
func (enum ListPrivilegesRequestOrderBy) Values() []ListPrivilegesRequestOrderBy
type ListPrivilegesResponse ¶
type ListPrivilegesResponse struct { // Privileges: privileges of a user in a database in a Database Instance. Privileges []*Privilege `json:"privileges"` // TotalCount: total count of privileges present on a database. TotalCount uint32 `json:"total_count"` }
ListPrivilegesResponse: list privileges response.
func (*ListPrivilegesResponse) UnsafeAppend ¶
func (r *ListPrivilegesResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListPrivilegesResponse) UnsafeGetTotalCount ¶
func (r *ListPrivilegesResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListSnapshotsRequest ¶
type ListSnapshotsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // Name: name of the snapshot. Name *string `json:"-"` // OrderBy: criteria to use when ordering snapshot listing. // Default value: created_at_asc OrderBy ListSnapshotsRequestOrderBy `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID *string `json:"-"` // OrganizationID: organization ID the snapshots belongs to. OrganizationID *string `json:"-"` // ProjectID: project ID the snapshots belongs to. ProjectID *string `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListSnapshotsRequest: list snapshots request.
type ListSnapshotsRequestOrderBy ¶
type ListSnapshotsRequestOrderBy string
func (ListSnapshotsRequestOrderBy) MarshalJSON ¶
func (enum ListSnapshotsRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListSnapshotsRequestOrderBy) String ¶
func (enum ListSnapshotsRequestOrderBy) String() string
func (*ListSnapshotsRequestOrderBy) UnmarshalJSON ¶
func (enum *ListSnapshotsRequestOrderBy) UnmarshalJSON(data []byte) error
func (ListSnapshotsRequestOrderBy) Values ¶
func (enum ListSnapshotsRequestOrderBy) Values() []ListSnapshotsRequestOrderBy
type ListSnapshotsResponse ¶
type ListSnapshotsResponse struct { // Snapshots: list of snapshots. Snapshots []*Snapshot `json:"snapshots"` // TotalCount: total count of snapshots available. TotalCount uint32 `json:"total_count"` }
ListSnapshotsResponse: list snapshots response.
func (*ListSnapshotsResponse) UnsafeAppend ¶
func (r *ListSnapshotsResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListSnapshotsResponse) UnsafeGetTotalCount ¶
func (r *ListSnapshotsResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type ListUsersRequest ¶
type ListUsersRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` // Name: name of the user. Name *string `json:"-"` // OrderBy: criteria to use when requesting user listing. // Default value: name_asc OrderBy ListUsersRequestOrderBy `json:"-"` Page *int32 `json:"-"` PageSize *uint32 `json:"-"` }
ListUsersRequest: list users request.
type ListUsersRequestOrderBy ¶
type ListUsersRequestOrderBy string
func (ListUsersRequestOrderBy) MarshalJSON ¶
func (enum ListUsersRequestOrderBy) MarshalJSON() ([]byte, error)
func (ListUsersRequestOrderBy) String ¶
func (enum ListUsersRequestOrderBy) String() string
func (*ListUsersRequestOrderBy) UnmarshalJSON ¶
func (enum *ListUsersRequestOrderBy) UnmarshalJSON(data []byte) error
func (ListUsersRequestOrderBy) Values ¶
func (enum ListUsersRequestOrderBy) Values() []ListUsersRequestOrderBy
type ListUsersResponse ¶
type ListUsersResponse struct { // Users: list of users in a Database Instance. Users []*User `json:"users"` // TotalCount: total count of users present on a Database Instance. TotalCount uint32 `json:"total_count"` }
ListUsersResponse: list users response.
func (*ListUsersResponse) UnsafeAppend ¶
func (r *ListUsersResponse) UnsafeAppend(res interface{}) (uint32, error)
UnsafeAppend should not be used Internal usage only
func (*ListUsersResponse) UnsafeGetTotalCount ¶
func (r *ListUsersResponse) UnsafeGetTotalCount() uint32
UnsafeGetTotalCount should not be used Internal usage only
type LogsPolicy ¶
type LogsPolicy struct { // MaxAgeRetention: max age (in days) of remote logs to keep on the Database Instance. MaxAgeRetention *uint32 `json:"max_age_retention"` // TotalDiskRetention: max disk size of remote logs to keep on the Database Instance. TotalDiskRetention *scw.Size `json:"total_disk_retention"` }
LogsPolicy: logs policy.
type Maintenance ¶
type Maintenance struct { // StartsAt: start date of the maintenance window. StartsAt *time.Time `json:"starts_at"` // StopsAt: end date of the maintenance window. StopsAt *time.Time `json:"stops_at"` // ClosedAt: closed maintenance date. ClosedAt *time.Time `json:"closed_at"` // Reason: maintenance information message. Reason string `json:"reason"` // Status: status of the maintenance. // Default value: unknown Status MaintenanceStatus `json:"status"` // ForcedAt: time when Scaleway-side maintenance will be applied. ForcedAt *time.Time `json:"forced_at"` }
Maintenance: maintenance.
type MaintenanceStatus ¶
type MaintenanceStatus string
func (MaintenanceStatus) MarshalJSON ¶
func (enum MaintenanceStatus) MarshalJSON() ([]byte, error)
func (MaintenanceStatus) String ¶
func (enum MaintenanceStatus) String() string
func (*MaintenanceStatus) UnmarshalJSON ¶
func (enum *MaintenanceStatus) UnmarshalJSON(data []byte) error
func (MaintenanceStatus) Values ¶
func (enum MaintenanceStatus) Values() []MaintenanceStatus
type MigrateEndpointRequest ¶
type MigrateEndpointRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // EndpointID: UUID of the endpoint you want to migrate. EndpointID string `json:"-"` // InstanceID: UUID of the instance you want to attach the endpoint to. InstanceID string `json:"instance_id"` }
MigrateEndpointRequest: migrate endpoint request.
type NodeType ¶
type NodeType struct { // Name: node Type name identifier. Name string `json:"name"` // StockStatus: current stock status for the Node Type. // Default value: unknown StockStatus NodeTypeStock `json:"stock_status"` // Description: current specs of the offer. Description string `json:"description"` // Vcpus: number of virtual CPUs. Vcpus uint32 `json:"vcpus"` // Memory: quantity of RAM. Memory scw.Size `json:"memory"` // Deprecated: VolumeConstraint: [deprecated] Node Type volume constraints. VolumeConstraint *NodeTypeVolumeConstraintSizes `json:"volume_constraint,omitempty"` // Deprecated: IsBssdCompatible: the Node Type is compliant with Block Storage. IsBssdCompatible *bool `json:"is_bssd_compatible,omitempty"` // Disabled: the Node Type is currently disabled. Disabled bool `json:"disabled"` // Beta: the Node Type is currently in beta. Beta bool `json:"beta"` // AvailableVolumeTypes: available storage options for the Node Type. AvailableVolumeTypes []*NodeTypeVolumeType `json:"available_volume_types"` // IsHaRequired: the Node Type can be used only with high availability option. IsHaRequired bool `json:"is_ha_required"` // Generation: generation associated with the NodeType offer. // Default value: unknown_generation Generation NodeTypeGeneration `json:"generation"` // InstanceRange: instance range associated with the NodeType offer. InstanceRange string `json:"instance_range"` // Region: region the Node Type is in. Region scw.Region `json:"region"` }
NodeType: node type.
type NodeTypeGeneration ¶
type NodeTypeGeneration string
func (NodeTypeGeneration) MarshalJSON ¶
func (enum NodeTypeGeneration) MarshalJSON() ([]byte, error)
func (NodeTypeGeneration) String ¶
func (enum NodeTypeGeneration) String() string
func (*NodeTypeGeneration) UnmarshalJSON ¶
func (enum *NodeTypeGeneration) UnmarshalJSON(data []byte) error
func (NodeTypeGeneration) Values ¶
func (enum NodeTypeGeneration) Values() []NodeTypeGeneration
type NodeTypeStock ¶
type NodeTypeStock string
func (NodeTypeStock) MarshalJSON ¶
func (enum NodeTypeStock) MarshalJSON() ([]byte, error)
func (NodeTypeStock) String ¶
func (enum NodeTypeStock) String() string
func (*NodeTypeStock) UnmarshalJSON ¶
func (enum *NodeTypeStock) UnmarshalJSON(data []byte) error
func (NodeTypeStock) Values ¶
func (enum NodeTypeStock) Values() []NodeTypeStock
type NodeTypeVolumeConstraintSizes ¶
type NodeTypeVolumeConstraintSizes struct { // MinSize: [deprecated] Mimimum size required for the Volume. MinSize scw.Size `json:"min_size"` // MaxSize: [deprecated] Maximum size required for the Volume. MaxSize scw.Size `json:"max_size"` }
NodeTypeVolumeConstraintSizes: node type volume constraint sizes.
type NodeTypeVolumeType ¶
type NodeTypeVolumeType struct { // Type: volume Type. // Default value: lssd Type VolumeType `json:"type"` // Description: the description of the Volume. Description string `json:"description"` // MinSize: mimimum size required for the Volume. MinSize scw.Size `json:"min_size"` // MaxSize: maximum size required for the Volume. MaxSize scw.Size `json:"max_size"` // ChunkSize: minimum increment level for a Block Storage volume size. ChunkSize scw.Size `json:"chunk_size"` // Class: the storage class of the volume. // Default value: unknown_storage_class Class StorageClass `json:"class"` }
NodeTypeVolumeType: node type volume type.
type Permission ¶
type Permission string
func (Permission) MarshalJSON ¶
func (enum Permission) MarshalJSON() ([]byte, error)
func (Permission) String ¶
func (enum Permission) String() string
func (*Permission) UnmarshalJSON ¶
func (enum *Permission) UnmarshalJSON(data []byte) error
func (Permission) Values ¶
func (enum Permission) Values() []Permission
type PrepareInstanceLogsRequest ¶
type PrepareInstanceLogsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want logs of. InstanceID string `json:"-"` // StartDate: start datetime of your log. (RFC 3339 format). StartDate *time.Time `json:"start_date,omitempty"` // EndDate: end datetime of your log. (RFC 3339 format). EndDate *time.Time `json:"end_date,omitempty"` }
PrepareInstanceLogsRequest: prepare instance logs request.
type PrepareInstanceLogsResponse ¶
type PrepareInstanceLogsResponse struct { // InstanceLogs: instance logs for a Database Instance between a start and an end date. InstanceLogs []*InstanceLog `json:"instance_logs"` }
PrepareInstanceLogsResponse: prepare instance logs response.
type Privilege ¶
type Privilege struct { // Permission: permission (Read, Read/Write, All, Custom). // Default value: readonly Permission Permission `json:"permission"` // DatabaseName: name of the database. DatabaseName string `json:"database_name"` // UserName: name of the user. UserName string `json:"user_name"` }
Privilege: privilege.
type PromoteReadReplicaRequest ¶
type PromoteReadReplicaRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // ReadReplicaID: UUID of the Read Replica. ReadReplicaID string `json:"-"` }
PromoteReadReplicaRequest: promote read replica request.
type PurgeInstanceLogsRequest ¶
type PurgeInstanceLogsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want logs of. InstanceID string `json:"-"` // LogName: given log name to purge. LogName *string `json:"log_name,omitempty"` }
PurgeInstanceLogsRequest: purge instance logs request.
type ReadReplica ¶
type ReadReplica struct { // ID: UUID of the Read Replica. ID string `json:"id"` // Endpoints: display Read Replica connection information. Endpoints []*Endpoint `json:"endpoints"` // Status: read replica status. // Default value: unknown Status ReadReplicaStatus `json:"status"` // Region: region the Read Replica is in. Region scw.Region `json:"region"` // SameZone: whether the replica is in the same availability zone as the main instance nodes or not. SameZone bool `json:"same_zone"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"instance_id"` }
ReadReplica: read replica.
type ReadReplicaEndpointSpec ¶
type ReadReplicaEndpointSpec struct { // DirectAccess: direct access endpoint specifications. Public endpoint reserved for Read Replicas. One per Read Replica. // Precisely one of DirectAccess, PrivateNetwork must be set. DirectAccess *ReadReplicaEndpointSpecDirectAccess `json:"direct_access,omitempty"` // PrivateNetwork: private Network endpoint specifications. One at the most per Read Replica. Cannot be updated (has to be deleted and recreated). // Precisely one of DirectAccess, PrivateNetwork must be set. PrivateNetwork *ReadReplicaEndpointSpecPrivateNetwork `json:"private_network,omitempty"` }
ReadReplicaEndpointSpec: read replica endpoint spec.
type ReadReplicaEndpointSpecDirectAccess ¶
type ReadReplicaEndpointSpecDirectAccess struct { }
ReadReplicaEndpointSpecDirectAccess: read replica endpoint spec direct access.
type ReadReplicaEndpointSpecPrivateNetwork ¶
type ReadReplicaEndpointSpecPrivateNetwork struct { // PrivateNetworkID: UUID of the Private Network to be connected to the Read Replica. PrivateNetworkID string `json:"private_network_id"` // ServiceIP: endpoint IPv4 address with a CIDR notation. Refer to the official Scaleway documentation to learn more about IP and subnet limitations. // Precisely one of ServiceIP, IpamConfig must be set. ServiceIP *scw.IPNet `json:"service_ip,omitempty"` // IpamConfig: automated configuration of your Private Network endpoint with Scaleway IPAM service. One at the most per Database Instance or Read Replica (a Database Instance and its Read Replica can have different private networks). Cannot be updated (has to be deleted and recreated). // Precisely one of ServiceIP, IpamConfig must be set. IpamConfig *ReadReplicaEndpointSpecPrivateNetworkIpamConfig `json:"ipam_config,omitempty"` }
ReadReplicaEndpointSpecPrivateNetwork: read replica endpoint spec private network.
type ReadReplicaEndpointSpecPrivateNetworkIpamConfig ¶
type ReadReplicaEndpointSpecPrivateNetworkIpamConfig struct { }
ReadReplicaEndpointSpecPrivateNetworkIpamConfig: read replica endpoint spec private network ipam config.
type ReadReplicaStatus ¶
type ReadReplicaStatus string
func (ReadReplicaStatus) MarshalJSON ¶
func (enum ReadReplicaStatus) MarshalJSON() ([]byte, error)
func (ReadReplicaStatus) String ¶
func (enum ReadReplicaStatus) String() string
func (*ReadReplicaStatus) UnmarshalJSON ¶
func (enum *ReadReplicaStatus) UnmarshalJSON(data []byte) error
func (ReadReplicaStatus) Values ¶
func (enum ReadReplicaStatus) Values() []ReadReplicaStatus
type RenewInstanceCertificateRequest ¶
type RenewInstanceCertificateRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want logs of. InstanceID string `json:"-"` }
RenewInstanceCertificateRequest: renew instance certificate request.
type ResetReadReplicaRequest ¶
type ResetReadReplicaRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // ReadReplicaID: UUID of the Read Replica. ReadReplicaID string `json:"-"` }
ResetReadReplicaRequest: reset read replica request.
type RestartInstanceRequest ¶
type RestartInstanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to restart. InstanceID string `json:"-"` }
RestartInstanceRequest: restart instance request.
type RestoreDatabaseBackupRequest ¶
type RestoreDatabaseBackupRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // DatabaseBackupID: backup of a logical database. DatabaseBackupID string `json:"-"` // DatabaseName: defines the destination database to restore into a specified database (the default destination is set to the origin database of the backup). DatabaseName *string `json:"database_name,omitempty"` // InstanceID: defines the Database Instance where the backup has to be restored. InstanceID string `json:"instance_id"` }
RestoreDatabaseBackupRequest: restore database backup request.
type SetInstanceACLRulesRequest ¶
type SetInstanceACLRulesRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance where the ACL rules must be set. InstanceID string `json:"-"` // Rules: ACL rules to define for the Database Instance. Rules []*ACLRuleRequest `json:"rules"` }
SetInstanceACLRulesRequest: set instance acl rules request.
type SetInstanceACLRulesResponse ¶
type SetInstanceACLRulesResponse struct { // Rules: aCLs rules configured for a Database Instance. Rules []*ACLRule `json:"rules"` }
SetInstanceACLRulesResponse: set instance acl rules response.
type SetInstanceSettingsRequest ¶
type SetInstanceSettingsRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance where the settings must be set. InstanceID string `json:"-"` // Settings: settings to define for the Database Instance. Settings []*InstanceSetting `json:"settings"` }
SetInstanceSettingsRequest: set instance settings request.
type SetInstanceSettingsResponse ¶
type SetInstanceSettingsResponse struct { // Settings: settings configured for a Database Instance. Settings []*InstanceSetting `json:"settings"` }
SetInstanceSettingsResponse: set instance settings response.
type SetPrivilegeRequest ¶
type SetPrivilegeRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"-"` // DatabaseName: name of the database. DatabaseName string `json:"database_name"` // UserName: name of the user. UserName string `json:"user_name"` // Permission: permission to set (Read, Read/Write, All, Custom). // Default value: readonly Permission Permission `json:"permission"` }
SetPrivilegeRequest: set privilege request.
type Snapshot ¶
type Snapshot struct { // ID: UUID of the snapshot. ID string `json:"id"` // InstanceID: UUID of the Database Instance. InstanceID string `json:"instance_id"` // Name: name of the snapshot. Name string `json:"name"` // Status: status of the snapshot. // Default value: unknown Status SnapshotStatus `json:"status"` // Size: size of the snapshot. Size *scw.Size `json:"size"` // ExpiresAt: expiration date (must follow the ISO 8601 format). ExpiresAt *time.Time `json:"expires_at"` // CreatedAt: creation date (must follow the ISO 8601 format). CreatedAt *time.Time `json:"created_at"` // UpdatedAt: updated date (must follow the ISO 8601 format). UpdatedAt *time.Time `json:"updated_at"` // InstanceName: name of the Database Instance of the snapshot. InstanceName string `json:"instance_name"` // NodeType: source node type. NodeType string `json:"node_type"` // VolumeType: type of volume where data is stored (lssd, bssd or sbs). VolumeType *SnapshotVolumeType `json:"volume_type"` // Region: region of this snapshot. Region scw.Region `json:"region"` }
Snapshot: snapshot.
type SnapshotStatus ¶
type SnapshotStatus string
func (SnapshotStatus) MarshalJSON ¶
func (enum SnapshotStatus) MarshalJSON() ([]byte, error)
func (SnapshotStatus) String ¶
func (enum SnapshotStatus) String() string
func (*SnapshotStatus) UnmarshalJSON ¶
func (enum *SnapshotStatus) UnmarshalJSON(data []byte) error
func (SnapshotStatus) Values ¶
func (enum SnapshotStatus) Values() []SnapshotStatus
type SnapshotVolumeType ¶
type SnapshotVolumeType struct { // Type: default value: lssd Type VolumeType `json:"type"` // Class: default value: unknown_storage_class Class StorageClass `json:"class"` }
SnapshotVolumeType: snapshot volume type.
type StorageClass ¶
type StorageClass string
func (StorageClass) MarshalJSON ¶
func (enum StorageClass) MarshalJSON() ([]byte, error)
func (StorageClass) String ¶
func (enum StorageClass) String() string
func (*StorageClass) UnmarshalJSON ¶
func (enum *StorageClass) UnmarshalJSON(data []byte) error
func (StorageClass) Values ¶
func (enum StorageClass) Values() []StorageClass
type UpdateDatabaseBackupRequest ¶
type UpdateDatabaseBackupRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // DatabaseBackupID: UUID of the database backup to update. DatabaseBackupID string `json:"-"` // Name: name of the Database Backup. Name *string `json:"name,omitempty"` // ExpiresAt: expiration date (must follow the ISO 8601 format). ExpiresAt *time.Time `json:"expires_at,omitempty"` }
UpdateDatabaseBackupRequest: update database backup request.
type UpdateInstanceRequest ¶
type UpdateInstanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance to update. InstanceID string `json:"-"` // BackupScheduleFrequency: in hours. BackupScheduleFrequency *uint32 `json:"backup_schedule_frequency,omitempty"` // BackupScheduleRetention: in days. BackupScheduleRetention *uint32 `json:"backup_schedule_retention,omitempty"` // IsBackupScheduleDisabled: defines whether or not the backup schedule is disabled. IsBackupScheduleDisabled *bool `json:"is_backup_schedule_disabled,omitempty"` // Name: name of the Database Instance. Name *string `json:"name,omitempty"` // Tags: tags of a Database Instance. Tags *[]string `json:"tags,omitempty"` // LogsPolicy: logs policy of the Database Instance. LogsPolicy *LogsPolicy `json:"logs_policy,omitempty"` // BackupSameRegion: store logical backups in the same region as the Database Instance. BackupSameRegion *bool `json:"backup_same_region,omitempty"` // BackupScheduleStartHour: defines the start time of the autobackup. BackupScheduleStartHour *uint32 `json:"backup_schedule_start_hour,omitempty"` }
UpdateInstanceRequest: update instance request.
type UpdateSnapshotRequest ¶
type UpdateSnapshotRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // SnapshotID: UUID of the snapshot to update. SnapshotID string `json:"-"` // Name: name of the snapshot. Name *string `json:"name,omitempty"` // ExpiresAt: expiration date (must follow the ISO 8601 format). ExpiresAt *time.Time `json:"expires_at,omitempty"` }
UpdateSnapshotRequest: update snapshot request.
type UpdateUserRequest ¶
type UpdateUserRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance the user belongs to. InstanceID string `json:"-"` // Name: name of the database user. Name string `json:"-"` // Password: password of the database user. Password *string `json:"password,omitempty"` // IsAdmin: defines whether or not this user got administrative privileges. IsAdmin *bool `json:"is_admin,omitempty"` }
UpdateUserRequest: update user request.
type UpgradableVersion ¶
type UpgradableVersion struct { ID string `json:"id"` Name string `json:"name"` Version string `json:"version"` MinorVersion string `json:"minor_version"` }
UpgradableVersion: upgradable version.
type UpgradeInstanceRequest ¶
type UpgradeInstanceRequest struct { // Region: region to target. If none is passed will use default region from the config. Region scw.Region `json:"-"` // InstanceID: UUID of the Database Instance you want to upgrade. InstanceID string `json:"-"` // NodeType: node type of the Database Instance you want to upgrade to. // Precisely one of NodeType, EnableHa, VolumeSize, VolumeType, UpgradableVersionID, MajorUpgradeWorkflow must be set. NodeType *string `json:"node_type,omitempty"` // EnableHa: defines whether or not high availability should be enabled on the Database Instance. // Precisely one of NodeType, EnableHa, VolumeSize, VolumeType, UpgradableVersionID, MajorUpgradeWorkflow must be set. EnableHa *bool `json:"enable_ha,omitempty"` // VolumeSize: increase your block storage volume size. // Precisely one of NodeType, EnableHa, VolumeSize, VolumeType, UpgradableVersionID, MajorUpgradeWorkflow must be set. VolumeSize *uint64 `json:"volume_size,omitempty"` // VolumeType: change your Database Instance storage type. // Default value: lssd // Precisely one of NodeType, EnableHa, VolumeSize, VolumeType, UpgradableVersionID, MajorUpgradeWorkflow must be set. VolumeType *VolumeType `json:"volume_type,omitempty"` // UpgradableVersionID: this will create a new Database Instance with same specifications as the current one and perform a Database Engine upgrade. // Precisely one of NodeType, EnableHa, VolumeSize, VolumeType, UpgradableVersionID, MajorUpgradeWorkflow must be set. UpgradableVersionID *string `json:"upgradable_version_id,omitempty"` // MajorUpgradeWorkflow: upgrade your database engine to a new major version including instance endpoints. // Precisely one of NodeType, EnableHa, VolumeSize, VolumeType, UpgradableVersionID, MajorUpgradeWorkflow must be set. MajorUpgradeWorkflow *UpgradeInstanceRequestMajorUpgradeWorkflow `json:"major_upgrade_workflow,omitempty"` }
UpgradeInstanceRequest: upgrade instance request.
type UpgradeInstanceRequestMajorUpgradeWorkflow ¶
type UpgradeInstanceRequestMajorUpgradeWorkflow struct { // UpgradableVersionID: this will create a new Database Instance with same specifications as the current one and perform a Database Engine upgrade. UpgradableVersionID string `json:"upgradable_version_id"` // WithEndpoints: at the end of the migration procedure this option let you migrate all your database endpoint to the upgraded instance. WithEndpoints bool `json:"with_endpoints"` }
UpgradeInstanceRequestMajorUpgradeWorkflow: upgrade instance request major upgrade workflow.
type User ¶
type User struct { // Name: name of the user (Length must be between 1 and 63 characters for PostgreSQL and between 1 and 32 characters for MySQL. First character must be an alphabet character (a-zA-Z). Your username cannot start with '_rdb' or in PostgreSQL, 'pg_'. Only a-zA-Z0-9_$- characters are accepted). Name string `json:"name"` // IsAdmin: defines whether or not a user got administrative privileges on the Database Instance. IsAdmin bool `json:"is_admin"` }
User: user.
type Volume ¶
type Volume struct { // Type: default value: lssd Type VolumeType `json:"type"` Size scw.Size `json:"size"` // Class: default value: unknown_storage_class Class StorageClass `json:"class"` }
Volume: volume.
type VolumeType ¶
type VolumeType string
func (VolumeType) MarshalJSON ¶
func (enum VolumeType) MarshalJSON() ([]byte, error)
func (VolumeType) String ¶
func (enum VolumeType) String() string
func (*VolumeType) UnmarshalJSON ¶
func (enum *VolumeType) UnmarshalJSON(data []byte) error
func (VolumeType) Values ¶
func (enum VolumeType) Values() []VolumeType