-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
resource/aws_service_discovery_service: Support routing policy and update the type of dns record #3273
resource/aws_service_discovery_service: Support routing policy and update the type of dns record #3273
Conversation
Hi @atsushi-ishibashi Thanks. |
Ah, sorry it was raised in #3272 😅 - which was merged, in which case do you mind rebasing the PR? 😃 |
…date the type of dns record
3bc7446
to
8ccaa72
Compare
@radeksimko OK👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR @atsushi-ishibashi
The old version of config should still work after upgrading the provider. We shouldn't be forcing the user to add the new field to their config - or that would be considered a breaking change.
We can avoid the breaking change by setting the field to MULTIVALUE
during state migration. Do you think you could look into adding a state migration?
@@ -210,6 +214,7 @@ resource "aws_service_discovery_service" "test" { | |||
ttl = 5 | |||
type = "A" | |||
} | |||
routing_policy = "WEIGHTED" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some funny indentation here 👀
Optional: true, | ||
ForceNew: true, | ||
ValidateFunc: validateStringIn("MULTIVALUE", "WEIGHTED"), | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since the API defaults to MULTIVALUE
shouldn't we also set it as Default
here to avoid diffs when the field is not defined?
@radeksimko Ok👍
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @atsushi-ishibashi
this LGTM, I just removed the new field from one test so we have some coverage in that area too. After all we shouldn't just assume everyone will use this field.
This has been released in version 1.10.0 of the AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Required: #3272
After merged, I'll remove the commit.