Remove hardcode from heat service
Also create timeout was increased, and heat job will be more stable. Change-Id: Ib569166830463b97e485024af5127a4005f5f530
This commit is contained in:
parent
d8b4443fe7
commit
acd13d104e
@ -11,11 +11,14 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from oslo_config import cfg
|
||||
|
||||
from rally.common import utils as common_utils
|
||||
from rally.task import atomic
|
||||
from rally.task import utils
|
||||
|
||||
CONF = cfg.CONF
|
||||
|
||||
|
||||
class Stack(common_utils.RandomNameGeneratorMixin):
|
||||
"""Represent heat stack.
|
||||
@ -48,8 +51,8 @@ class Stack(common_utils.RandomNameGeneratorMixin):
|
||||
def _wait(self, ready_statuses, failure_statuses):
|
||||
self.stack = utils.wait_for_status(
|
||||
self.stack,
|
||||
check_interval=10,
|
||||
timeout=1200,
|
||||
check_interval=CONF.benchmark.heat_stack_create_poll_interval,
|
||||
timeout=CONF.benchmark.heat_stack_create_timeout,
|
||||
ready_statuses=ready_statuses,
|
||||
failure_statuses=failure_statuses,
|
||||
update_resource=utils.get_from_manager(),
|
||||
|
@ -48,10 +48,10 @@ class StackTestCase(test.ScenarioTestCase):
|
||||
stack.stack = fake_stack = mock.Mock()
|
||||
stack._wait(["ready_statuses"], ["failure_statuses"])
|
||||
mock_utils.wait_for_status.assert_called_once_with(
|
||||
fake_stack, check_interval=10,
|
||||
fake_stack, check_interval=1.0,
|
||||
ready_statuses=["ready_statuses"],
|
||||
failure_statuses=["failure_statuses"],
|
||||
timeout=1200,
|
||||
timeout=3600.0,
|
||||
update_resource=mock_utils.get_from_manager())
|
||||
|
||||
@mock.patch("rally.task.atomic")
|
||||
|
Loading…
Reference in New Issue
Block a user