diff --git a/specification/resources/databases/databases_create_cluster.yml b/specification/resources/databases/databases_create_cluster.yml index cee50a91..f065dc01 100644 --- a/specification/resources/databases/databases_create_cluster.yml +++ b/specification/resources/databases/databases_create_cluster.yml @@ -45,6 +45,7 @@ requestBody: version: "14" region: nyc3 size: db-s-2vcpu-4gb + storage_size_mib: 61440 num_nodes: 2 tags: - production @@ -57,6 +58,7 @@ requestBody: region: nyc3 size: db-s-2vcpu-4gb num_nodes: 2 + storage_size_mib: 61440 tags: - production rules: diff --git a/specification/resources/databases/databases_update_clusterSize.yml b/specification/resources/databases/databases_update_clusterSize.yml index abf03905..03adabd5 100644 --- a/specification/resources/databases/databases_update_clusterSize.yml +++ b/specification/resources/databases/databases_update_clusterSize.yml @@ -29,6 +29,7 @@ requestBody: example: size: db-s-4vcpu-8gb num_nodes: 3 + storage_size_mib: 163840 responses: '202': diff --git a/specification/resources/databases/examples/curl/databases_create_cluster.yml b/specification/resources/databases/examples/curl/databases_create_cluster.yml index e398fd32..a7b9d8b7 100644 --- a/specification/resources/databases/examples/curl/databases_create_cluster.yml +++ b/specification/resources/databases/examples/curl/databases_create_cluster.yml @@ -3,5 +3,5 @@ source: |- curl -X POST \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \ - -d '{"name": "backend", "engine": "pg", "version": "14", "region": "nyc3", "size": "db-s-2vcpu-4gb", "num_nodes": 2, "tags": ["production"]}' \ + -d '{"name": "backend", "engine": "pg", "version": "14", "region": "nyc3", "size": "db-s-2vcpu-4gb", "num_nodes": 2, "storage_size_mib": 61440, "tags": ["production"]}' \ "https://api.digitalocean.com/v2/databases" diff --git a/specification/resources/databases/examples/curl/databases_update_clusterSize.yml b/specification/resources/databases/examples/curl/databases_update_clusterSize.yml index 38eb3b8e..1adc9bae 100644 --- a/specification/resources/databases/examples/curl/databases_update_clusterSize.yml +++ b/specification/resources/databases/examples/curl/databases_update_clusterSize.yml @@ -3,5 +3,5 @@ source: |- curl -X PUT \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \ - -d '{"size":"db-s-4vcpu-8gb", "num_nodes":3}' \ + -d '{"size":"db-s-4vcpu-8gb", "num_nodes":3, "storage_size_mib":163840}' \ "https://api.digitalocean.com/v2/databases/9cc10173-e9ea-4176-9dbc-a4cee4c4ff30/resize" diff --git a/specification/resources/databases/examples/go/databases_create_cluster.yml b/specification/resources/databases/examples/go/databases_create_cluster.yml index 6749fd09..468afe92 100644 --- a/specification/resources/databases/examples/go/databases_create_cluster.yml +++ b/specification/resources/databases/examples/go/databases_create_cluster.yml @@ -20,6 +20,7 @@ source: |- Region: "nyc3", SizeSlug: "db-s-2vcpu-4gb", NumNodes: 2, + StorageSizeMiB : 61440, } cluster, _, err := client.Databases.Create(ctx, createRequest) diff --git a/specification/resources/databases/examples/go/databases_update_clusterSize.yml b/specification/resources/databases/examples/go/databases_update_clusterSize.yml index 9fa79953..91f504d1 100644 --- a/specification/resources/databases/examples/go/databases_update_clusterSize.yml +++ b/specification/resources/databases/examples/go/databases_update_clusterSize.yml @@ -14,5 +14,6 @@ source: |- resizeRequest := &godo.DatabaseResizeRequest{ SizeSlug: "db-s-4vcpu-8gb", NumNodes: 3, + StorageSizeMib: 163840, } } diff --git a/specification/resources/databases/examples/python/databases_create_cluster.yml b/specification/resources/databases/examples/python/databases_create_cluster.yml index b7a2ad4e..6867c543 100644 --- a/specification/resources/databases/examples/python/databases_create_cluster.yml +++ b/specification/resources/databases/examples/python/databases_create_cluster.yml @@ -12,6 +12,7 @@ source: |- "region": "nyc3", "size": "db-s-2vcpu-4gb", "num_nodes": 2, + "storage_size_mib": 61440, "tags": [ "production" ] diff --git a/specification/resources/databases/examples/python/databases_update_clusterSize.yml b/specification/resources/databases/examples/python/databases_update_clusterSize.yml index 58001ef3..b5d910d3 100644 --- a/specification/resources/databases/examples/python/databases_update_clusterSize.yml +++ b/specification/resources/databases/examples/python/databases_update_clusterSize.yml @@ -7,7 +7,8 @@ source: |- req = { "size": "db-s-4vcpu-8gb", - "num_nodes": 3 + "num_nodes": 3, + "storage_size_mib": 163840 } update_resp = client.databases.update_cluster_size(database_cluster_uuid="a7a8bas", body=req) diff --git a/specification/resources/databases/models/database_cluster.yml b/specification/resources/databases/models/database_cluster.yml index 66720cd7..59e564b3 100644 --- a/specification/resources/databases/models/database_cluster.yml +++ b/specification/resources/databases/models/database_cluster.yml @@ -133,6 +133,12 @@ properties: description: >- A timestamp referring to the date when the particular version will no longer be available for creating new clusters. If null, the version does not have an end of availability timeline. + storage_size_mib: + type: integer + example: 61440 + description: >- + Additional storage added to the cluster, in MiB. If null, no additional storage is added to the cluster, beyond + what is provided as a base amount from the 'size' and any previously added additional storage. required: diff --git a/specification/resources/databases/models/database_cluster_resize.yml b/specification/resources/databases/models/database_cluster_resize.yml index 31660db9..c3ba5e5b 100644 --- a/specification/resources/databases/models/database_cluster_resize.yml +++ b/specification/resources/databases/models/database_cluster_resize.yml @@ -13,6 +13,13 @@ properties: The number of nodes in the database cluster. Valid values are are 1-3. In addition to the primary node, up to two standby nodes may be added for highly available configurations. + storage_size_mib: + type: integer + example: 61440 + description: >- + Additional storage added to the cluster, in MiB. If null, no additional storage is added to the cluster, beyond + what is provided as a base amount from the 'size' and any previously added additional storage. + required: - size diff --git a/specification/resources/databases/responses/database_cluster.yml b/specification/resources/databases/responses/database_cluster.yml index 23ca6815..cb1f33ec 100644 --- a/specification/resources/databases/responses/database_cluster.yml +++ b/specification/resources/databases/responses/database_cluster.yml @@ -63,3 +63,4 @@ content: private_network_uuid: d455e75d-4858-4eec-8c95-da2f0a5f93a7 version_end_of_life: '2023-11-09T00:00:00Z' version_end_of_availability: '2023-05-09T00:00:00Z' + storage_size_mib: 61440 diff --git a/specification/resources/databases/responses/database_clusters.yml b/specification/resources/databases/responses/database_clusters.yml index e0496b14..44c918ad 100644 --- a/specification/resources/databases/responses/database_clusters.yml +++ b/specification/resources/databases/responses/database_clusters.yml @@ -61,3 +61,4 @@ content: private_network_uuid: d455e75d-4858-4eec-8c95-da2f0a5f93a7 version_end_of_life: '2023-11-09T00:00:00Z' version_end_of_availability: '2023-05-09T00:00:00Z' + storage_size_mib: 61440