Skip to content

Commit 6e32837

Browse files
authored
disk_size_auto_scaling_warning (#1142)
1 parent 436bbf7 commit 6e32837

File tree

2 files changed

+21
-2
lines changed

2 files changed

+21
-2
lines changed

website/docs/r/advanced_cluster.html.markdown

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,10 +370,21 @@ replication_specs {
370370
### auto_scaling
371371

372372
* `disk_gb_enabled` - (Optional) Flag that indicates whether this cluster enables disk auto-scaling. This parameter defaults to true.
373+
- Set to `true` to enable disk auto-scaling.
374+
- Set to `false` to disable disk auto-scaling.
375+
376+
~> **IMPORTANT:** If `disk_gb_enabled` is true, then Atlas will automatically scale disk size up and down.
377+
This will cause the value of `disk_size_gb` returned to potentially be different than what is specified in the Terraform config and if one then applies a plan, not noting this, Terraform will scale the cluster disk size back to the original `disk_size_gb` value.
378+
To prevent this a lifecycle customization should be used, i.e.:
379+
`lifecycle {
380+
ignore_changes = [disk_size_gb]
381+
}`
382+
After adding the `lifecycle` block to explicitly change `disk_size_gb` comment out the `lifecycle` block and run `terraform apply`. Please be sure to uncomment the `lifecycle` block once done to prevent any accidental changes.
383+
373384
* `compute_enabled` - (Optional) Flag that indicates whether instance size auto-scaling is enabled. This parameter defaults to false.
374385

375386
~> **IMPORTANT:** If `compute_enabled` is true, then Atlas will automatically scale up to the maximum provided and down to the minimum, if provided.
376-
This will cause the value of `instance_size` returned to potential be different than what is specified in the Terraform config and if one then applies a plan, not noting this, Terraform will scale the cluster back down to the original `instance_size` value.
387+
This will cause the value of `instance_size` returned to potentially be different than what is specified in the Terraform config and if one then applies a plan, not noting this, Terraform will scale the cluster back to the original `instance_size` value.
377388
To prevent this a lifecycle customization should be used, i.e.:
378389
`lifecycle {
379390
ignore_changes = [instance_size]

website/docs/r/cluster.html.markdown

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -287,14 +287,22 @@ Refer to the following for full privatelink endpoint connection string examples:
287287
- Set to `true` to enable disk auto-scaling.
288288
- Set to `false` to disable disk auto-scaling.
289289

290+
~> **IMPORTANT:** If `disk_gb_enabled` is true, then Atlas will automatically scale disk size up and down.
291+
This will cause the value of `disk_size_gb` returned to potentially be different than what is specified in the Terraform config and if one then applies a plan, not noting this, Terraform will scale the cluster disk size back to the original `disk_size_gb` value.
292+
To prevent this a lifecycle customization should be used, i.e.:
293+
`lifecycle {
294+
ignore_changes = [disk_size_gb]
295+
}`
296+
After adding the `lifecycle` block to explicitly change `disk_size_gb` comment out the `lifecycle` block and run `terraform apply`. Please be sure to uncomment the `lifecycle` block once done to prevent any accidental changes.
297+
290298
-> **NOTE:** If `provider_name` is set to `TENANT`, the parameter `auto_scaling_disk_gb_enabled` will be ignored.
291299

292300
* `auto_scaling_compute_enabled` - (Optional) Specifies whether cluster tier auto-scaling is enabled. The default is false.
293301
- Set to `true` to enable cluster tier auto-scaling. If enabled, you must specify a value for `providerSettings.autoScaling.compute.maxInstanceSize`.
294302
- Set to `false` to disable cluster tier auto-scaling.
295303

296304
~> **IMPORTANT:** If `auto_scaling_compute_enabled` is true, then Atlas will automatically scale up to the maximum provided and down to the minimum, if provided.
297-
This will cause the value of `provider_instance_size_name` returned to potential be different than what is specified in the Terraform config and if one then applies a plan, not noting this, Terraform will scale the cluster back down to the original instanceSizeName value.
305+
This will cause the value of `provider_instance_size_name` returned to potentially be different than what is specified in the Terraform config and if one then applies a plan, not noting this, Terraform will scale the cluster back to the original instanceSizeName value.
298306
To prevent this a lifecycle customization should be used, i.e.:
299307
`lifecycle {
300308
ignore_changes = [provider_instance_size_name]

0 commit comments

Comments
 (0)