Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: DBTP-896 - invalid opensearch config #73

Merged
merged 7 commits into from
Apr 19, 2024

Conversation

JohnStainsby
Copy link
Contributor

Make some OpenSearch properties conditional

  • availability_zone_count should only be set if zone_awareness_enabled is true
  • throughput is only a valid property for gp3 volumes

@JohnStainsby JohnStainsby requested a review from a team April 12, 2024 13:30
@@ -44,7 +32,7 @@ run "test_create_opensearch" {
}

assert {
condition = aws_opensearch_domain.this.cluster_config[0].dedicated_master_type == null
condition = aws_opensearch_domain.this.cluster_config[0].dedicated_master_type == ""
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even though it doesn't show in the terraform plan and it's an optional property dedicated_master_type gets deployed as an empty string

}

assert {
condition = aws_opensearch_domain.this.ebs_options[0].throughput == 0
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to dedicated_master_type this property gets deployed as 0 rather than null

@JohnStainsby JohnStainsby merged commit 7e30b05 into main Apr 19, 2024
5 checks passed
@JohnStainsby JohnStainsby deleted the DBTP-896-invalid-opensearch-settings branch April 19, 2024 10:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants