xds testing: remove distribution comparison in backends restart

This does not add any coverage beyond the existing round_robin checks,
and has a potential flake when any RPCs in the initial sampled
distribution (before restart) fail, we will get a skewed distribution
and be unable to match it after the restart.
pull/23927/head
Eric Gribkoff 5 years ago
parent 3d24907ac0
commit 214dbce0ca
  1. 10
      tools/run_tests/run_xds_tests.py

@ -403,7 +403,6 @@ def test_backends_restart(gcp, backend_service, instance_group):
start_time = time.time()
wait_until_all_rpcs_go_to_given_backends(instance_names,
_WAIT_FOR_STATS_SEC)
stats = get_client_stats(_NUM_TEST_RPCS, _WAIT_FOR_STATS_SEC)
try:
resize_instance_group(gcp, instance_group, 0)
wait_until_all_rpcs_go_to_given_backends_or_fail([],
@ -414,15 +413,6 @@ def test_backends_restart(gcp, backend_service, instance_group):
new_instance_names = get_instance_names(gcp, instance_group)
wait_until_all_rpcs_go_to_given_backends(new_instance_names,
_WAIT_FOR_BACKEND_SEC)
new_stats = get_client_stats(_NUM_TEST_RPCS, _WAIT_FOR_STATS_SEC)
original_distribution = list(stats.rpcs_by_peer.values())
original_distribution.sort()
new_distribution = list(new_stats.rpcs_by_peer.values())
new_distribution.sort()
threshold = 3
for i in range(len(original_distribution)):
if abs(original_distribution[i] - new_distribution[i]) > threshold:
raise Exception('Distributions do not match: ', stats, new_stats)
def test_change_backend_service(gcp, original_backend_service, instance_group,

Loading…
Cancel
Save