From b23c753e79172a2f865804854f80fb3b963d6f8e Mon Sep 17 00:00:00 2001 From: George Paraskevopoulos Date: Wed, 22 Mar 2017 16:15:56 +0200 Subject: Rewrite classification rules wait loop This is a candidate replacement for the wait_for_classification_rules function. The functionality is as follows: - Query ODL operational datastore for the RSPs for which we should expect to see flows in the computes (RSPs for which ACL rules exist) and associate them with a list of vnfs. Also get the tp_dst from the ACL match rules. - Use the known topology to associate the RSPs to a set of compute nodes (at this point we know that ODL promised us that we should see classification rules for a particular rsp in the nodes C1, C2 ...) - Gather the installed flows in table=11 in each compute - Verify that the RSPs are installed as promised by ODL for the correct tp_dst Change-Id: I79747ad1df3eb0c67f783167601b5ea99fb43f16 Signed-off-by: George Paraskevopoulos --- sfc/tests/functest/sfc_one_chain_two_service_functions.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'sfc/tests/functest/sfc_one_chain_two_service_functions.py') diff --git a/sfc/tests/functest/sfc_one_chain_two_service_functions.py b/sfc/tests/functest/sfc_one_chain_two_service_functions.py index e55af011..bdf6f1b4 100644 --- a/sfc/tests/functest/sfc_one_chain_two_service_functions.py +++ b/sfc/tests/functest/sfc_one_chain_two_service_functions.py @@ -51,6 +51,8 @@ def main(): compute_nodes = [node for node in openstack_nodes if node.is_compute()] + odl_ip, odl_port = test_utils.get_odl_ip_port(openstack_nodes) + for compute in compute_nodes: logger.info("This is a compute: %s" % compute.info) @@ -174,11 +176,10 @@ def main(): logger.info(test_utils.run_cmd('tacker sfc-list')[1]) logger.info(test_utils.run_cmd('tacker sfc-classifier-list')[1]) - num_chains = 1 - # Start measuring the time it takes to implement the classification rules t1 = threading.Thread(target=test_utils.wait_for_classification_rules, - args=(ovs_logger, compute_clients, num_chains,)) + args=(ovs_logger, compute_nodes, odl_ip, odl_port, + testTopology,)) try: t1.start() except Exception, e: -- cgit 1.2.3-korg