Merge "Delete amphora regardless of status"
This commit is contained in:
commit
3cc470755f
|
@ -17,7 +17,6 @@ import time
|
|||
|
||||
from oslo_config import cfg
|
||||
from oslo_log import log as logging
|
||||
import six
|
||||
from stevedore import driver as stevedore_driver
|
||||
from taskflow import task
|
||||
from taskflow.types import failure
|
||||
|
@ -151,10 +150,8 @@ class DeleteAmphoraeOnLoadBalancer(BaseComputeTask):
|
|||
"""
|
||||
|
||||
def execute(self, loadbalancer):
|
||||
for amp in six.moves.filter(
|
||||
lambda amp: amp.status == constants.AMPHORA_ALLOCATED,
|
||||
loadbalancer.amphorae):
|
||||
|
||||
for amp in loadbalancer.amphorae:
|
||||
# The compute driver will already handle NotFound
|
||||
try:
|
||||
self.compute.delete(amp.compute_id)
|
||||
except Exception:
|
||||
|
|
Loading…
Reference in New Issue