-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
provider/openstack: Rename provider to loadbalancer_provider #12239
Conversation
This commit renames provider to loadbalancer_provider in the openstack_lb_loadbalancer_v2 resource. It also changes security_group_ids to Computed so default security groups are added to the state correctly.
3b18512
to
4dc8df8
Compare
@@ -75,7 +75,7 @@ func resourceLoadBalancerV2() *schema.Resource { | |||
ForceNew: true, | |||
}, | |||
|
|||
"provider": &schema.Schema{ | |||
"loadbalancer_provider": &schema.Schema{ |
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.
I don't believe we can just make this change - it's not backwards compatible
We are going to have to deprecate provider
and then introduce the new loadbalancer_provider
field
we will have to cater for both until 0.10
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.
…vider This commit switches to using a deprecation path for removal of the previous "provider" argument in favor of the new "loadbalancer_provider".
if v, ok := d.GetOk("loadbalancer_provider"); ok { | ||
lbProvider = v.(string) | ||
} | ||
|
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.
@stack72 I couldn't decide on leaving this part as-is or adding the following:
if v, ok := d.GetOk("provider"); ok && lbProvider == "" {
lbProvider = v.(string)
}
The above would set lbProvider
if provider
was set and the new preferred loadbalancer_provider
wasn't set. However, since having an argument of provider
will error out anyway, is it worth adding the above block of code in?
FYI, I've validated this actually correctly sets the edit: disregard previous comments; secgroups change looks good. |
* provider/openstack: Rename provider to loadbalancer_provider This commit renames provider to loadbalancer_provider in the openstack_lb_loadbalancer_v2 resource. It also changes security_group_ids to Computed so default security groups are added to the state correctly. * provider/openstack: Switch to a deprecation path for loadbalancer provider This commit switches to using a deprecation path for removal of the previous "provider" argument in favor of the new "loadbalancer_provider".
…rp#12239) * provider/openstack: Rename provider to loadbalancer_provider This commit renames provider to loadbalancer_provider in the openstack_lb_loadbalancer_v2 resource. It also changes security_group_ids to Computed so default security groups are added to the state correctly. * provider/openstack: Switch to a deprecation path for loadbalancer provider This commit switches to using a deprecation path for removal of the previous "provider" argument in favor of the new "loadbalancer_provider".
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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
This commit renames provider to loadbalancer_provider in the
openstack_lb_loadbalancer_v2 resource.
It also changes security_group_ids to Computed so default
security groups are added to the state correctly.
Fixes #12237