Merge pull request #5557 from pfrybar/master
provider/openstack: Fix create/delete statuses in load balancing resources for openstack provider.
This commit is contained in:
commit
edb30d52c6
|
@ -85,6 +85,7 @@ func resourceLBMemberV1Create(d *schema.ResourceData, meta interface{}) error {
|
||||||
log.Printf("[DEBUG] Waiting for OpenStack LB member (%s) to become available.", m.ID)
|
log.Printf("[DEBUG] Waiting for OpenStack LB member (%s) to become available.", m.ID)
|
||||||
|
|
||||||
stateConf := &resource.StateChangeConf{
|
stateConf := &resource.StateChangeConf{
|
||||||
|
Pending: []string{"PENDING_CREATE"},
|
||||||
Target: []string{"ACTIVE"},
|
Target: []string{"ACTIVE"},
|
||||||
Refresh: waitForLBMemberActive(networkingClient, m.ID),
|
Refresh: waitForLBMemberActive(networkingClient, m.ID),
|
||||||
Timeout: 2 * time.Minute,
|
Timeout: 2 * time.Minute,
|
||||||
|
@ -158,7 +159,7 @@ func resourceLBMemberV1Delete(d *schema.ResourceData, meta interface{}) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
stateConf := &resource.StateChangeConf{
|
stateConf := &resource.StateChangeConf{
|
||||||
Pending: []string{"ACTIVE"},
|
Pending: []string{"ACTIVE", "PENDING_DELETE"},
|
||||||
Target: []string{"DELETED"},
|
Target: []string{"DELETED"},
|
||||||
Refresh: waitForLBMemberDelete(networkingClient, d.Id()),
|
Refresh: waitForLBMemberDelete(networkingClient, d.Id()),
|
||||||
Timeout: 2 * time.Minute,
|
Timeout: 2 * time.Minute,
|
||||||
|
|
|
@ -115,7 +115,7 @@ func resourceLBMonitorV1Create(d *schema.ResourceData, meta interface{}) error {
|
||||||
log.Printf("[DEBUG] Waiting for OpenStack LB Monitor (%s) to become available.", m.ID)
|
log.Printf("[DEBUG] Waiting for OpenStack LB Monitor (%s) to become available.", m.ID)
|
||||||
|
|
||||||
stateConf := &resource.StateChangeConf{
|
stateConf := &resource.StateChangeConf{
|
||||||
Pending: []string{"PENDING"},
|
Pending: []string{"PENDING_CREATE"},
|
||||||
Target: []string{"ACTIVE"},
|
Target: []string{"ACTIVE"},
|
||||||
Refresh: waitForLBMonitorActive(networkingClient, m.ID),
|
Refresh: waitForLBMonitorActive(networkingClient, m.ID),
|
||||||
Timeout: 2 * time.Minute,
|
Timeout: 2 * time.Minute,
|
||||||
|
@ -205,7 +205,7 @@ func resourceLBMonitorV1Delete(d *schema.ResourceData, meta interface{}) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
stateConf := &resource.StateChangeConf{
|
stateConf := &resource.StateChangeConf{
|
||||||
Pending: []string{"ACTIVE", "PENDING"},
|
Pending: []string{"ACTIVE", "PENDING_DELETE"},
|
||||||
Target: []string{"DELETED"},
|
Target: []string{"DELETED"},
|
||||||
Refresh: waitForLBMonitorDelete(networkingClient, d.Id()),
|
Refresh: waitForLBMonitorDelete(networkingClient, d.Id()),
|
||||||
Timeout: 2 * time.Minute,
|
Timeout: 2 * time.Minute,
|
||||||
|
|
|
@ -128,6 +128,7 @@ func resourceLBPoolV1Create(d *schema.ResourceData, meta interface{}) error {
|
||||||
log.Printf("[DEBUG] Waiting for OpenStack LB pool (%s) to become available.", p.ID)
|
log.Printf("[DEBUG] Waiting for OpenStack LB pool (%s) to become available.", p.ID)
|
||||||
|
|
||||||
stateConf := &resource.StateChangeConf{
|
stateConf := &resource.StateChangeConf{
|
||||||
|
Pending: []string{"PENDING_CREATE"},
|
||||||
Target: []string{"ACTIVE"},
|
Target: []string{"ACTIVE"},
|
||||||
Refresh: waitForLBPoolActive(networkingClient, p.ID),
|
Refresh: waitForLBPoolActive(networkingClient, p.ID),
|
||||||
Timeout: 2 * time.Minute,
|
Timeout: 2 * time.Minute,
|
||||||
|
@ -291,7 +292,7 @@ func resourceLBPoolV1Delete(d *schema.ResourceData, meta interface{}) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
stateConf := &resource.StateChangeConf{
|
stateConf := &resource.StateChangeConf{
|
||||||
Pending: []string{"ACTIVE"},
|
Pending: []string{"ACTIVE", "PENDING_DELETE"},
|
||||||
Target: []string{"DELETED"},
|
Target: []string{"DELETED"},
|
||||||
Refresh: waitForLBPoolDelete(networkingClient, d.Id()),
|
Refresh: waitForLBPoolDelete(networkingClient, d.Id()),
|
||||||
Timeout: 2 * time.Minute,
|
Timeout: 2 * time.Minute,
|
||||||
|
|
|
@ -264,7 +264,7 @@ func resourceLBVipV1Delete(d *schema.ResourceData, meta interface{}) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
stateConf := &resource.StateChangeConf{
|
stateConf := &resource.StateChangeConf{
|
||||||
Pending: []string{"ACTIVE"},
|
Pending: []string{"ACTIVE", "PENDING_DELETE"},
|
||||||
Target: []string{"DELETED"},
|
Target: []string{"DELETED"},
|
||||||
Refresh: waitForLBVIPDelete(networkingClient, d.Id()),
|
Refresh: waitForLBVIPDelete(networkingClient, d.Id()),
|
||||||
Timeout: 2 * time.Minute,
|
Timeout: 2 * time.Minute,
|
||||||
|
|
Loading…
Reference in New Issue