Skip to content

Commit

Permalink
fix: Removing store validity tests from stress.py (#3170)
Browse files Browse the repository at this point in the history
Store validity checks are executed on each `get_status` and take up to 1.5 seconds, during which they block `Client`.
In stress.py specifically they quickly get to actually taking 1.5 seconds, thus each time the test calls to `get_status`, one of the nodes gets blocked for 1.5s.

Removing ongoing store validity checks from stress.py, and introducing them only once at the end.

Test plan:
----------
stress.py now can actually pass in nayduck:
http://nayduck.eastus.cloudapp.azure.com:3000/#/run/93

The failure is a new issue: #3169
  • Loading branch information
SkidanovAlex authored Aug 14, 2020
1 parent 7028068 commit cb0d533
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pytest/tests/stress/stress.py
Original file line number Diff line number Diff line change
Expand Up @@ -561,12 +561,14 @@ def doit(s, n, N, k, monkeys, timeout):
started = time.time()

boot_node = spin_up_node(config, near_root, node_dirs[0], 0, None, None)
boot_node.stop_checking_store()
boot_node.mess_with = False
nodes = [boot_node]

for i in range(1, N + k + 1):
node = spin_up_node(config, near_root, node_dirs[i], i,
boot_node.node_key.pk, boot_node.addr())
node.stop_checking_store()
nodes.append(node)
if i >= n and i < N:
node.kill()
Expand Down Expand Up @@ -641,6 +643,11 @@ def check_errors():

check_errors()

logging.info("Shut down complete, executing store validity checks")
for node in nodes:
node.is_check_store = True
node.check_store()


MONKEYS = dict([(name[7:], obj)
for name, obj in inspect.getmembers(sys.modules[__name__])
Expand Down

0 comments on commit cb0d533

Please sign in to comment.