Added wait_for_node_to_be_ready to starting stopped storage nodes #29

Merged
abereziny merged 1 commit from ylukoyan/frostfs-testlib:fixture_start_storage into master 2023-05-29 14:01:58 +00:00

View file

@ -7,6 +7,7 @@ from frostfs_testlib.reporter import get_reporter
from frostfs_testlib.shell import CommandOptions, Shell from frostfs_testlib.shell import CommandOptions, Shell
from frostfs_testlib.steps import epoch from frostfs_testlib.steps import epoch
from frostfs_testlib.storage.cluster import Cluster, ClusterNode, StorageNode from frostfs_testlib.storage.cluster import Cluster, ClusterNode, StorageNode
from frostfs_testlib.steps.node_management import wait_for_node_to_be_ready
from frostfs_testlib.storage.controllers.disk_controller import DiskController from frostfs_testlib.storage.controllers.disk_controller import DiskController
from frostfs_testlib.testing.test_control import run_optionally, wait_for_success from frostfs_testlib.testing.test_control import run_optionally, wait_for_success
from frostfs_testlib.utils.failover_utils import ( from frostfs_testlib.utils.failover_utils import (
@ -90,6 +91,7 @@ class ClusterStateController:
def start_stopped_storage_services(self): def start_stopped_storage_services(self):
for node in self.stopped_storage_nodes: for node in self.stopped_storage_nodes:
node.start_service() node.start_service()
wait_all_storage_nodes_returned(self.shell, self.cluster)
self.stopped_storage_nodes = [] self.stopped_storage_nodes = []
@run_optionally(optionals.OPTIONAL_FAILOVER_ENABLED) @run_optionally(optionals.OPTIONAL_FAILOVER_ENABLED)