Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ACL] Add Tunnel Next Hop redirect support #3399

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Merge branch 'master' into tunn_nh

4c60841
Select commit
Loading
Failed to load commit list.
Open

[ACL] Add Tunnel Next Hop redirect support #3399

Merge branch 'master' into tunn_nh
4c60841
Select commit
Loading
Failed to load commit list.
Azure Pipelines / Azure.sonic-swss succeeded Dec 7, 2024 in 2h 12m 48s

Build #20241206.25 had test failures

Details

Tests

  • Failed: 1 (0.06%)
  • Passed: 1,660 (93.10%)
  • Other: 122 (6.84%)
  • Total: 1,783
Code coverage

  • 44630 of 65772 lines covered (67.86%)

Annotations

Check failure on line 5725 in Build log

See this annotation in the file changed.

@azure-pipelines azure-pipelines / Azure.sonic-swss

Build log #L5725

Bash exited with code '123'.

Check failure on line 1 in test_OverlayEntryTestMetaDataMgr

See this annotation in the file changed.

@azure-pipelines azure-pipelines / Azure.sonic-swss

test_OverlayEntryTestMetaDataMgr

AssertionError: Unexpected number of keys: expected=14, received=0 ([]), table="ASIC_STATE:SAI_OBJECT_TYPE_ACL_ENTRY"
Raw output
self = <test_acl_mark.TestAclMarkMeta object at 0x7f6ec8dd9550>
dvs_acl = <dvslib.dvs_acl.DVSAcl object at 0x7f6ec8dd9490>
overlay_acl_table = ['oid:0x7000000000761', 'oid:0x700000000076a']

    def test_OverlayEntryTestMetaDataMgr(self, dvs_acl, overlay_acl_table):
        # allocate all 7 metadata values and free them multiple times.
        # At the end there should be no rules allocated.
        for i in range(1, 4):
            config_qualifiers = {"DST_IP": "20.0.0.1/32",
                                "SRC_IP": "10.0.0.0/32",
                                "DSCP": "1"
                                }
            acl_table_id = dvs_acl.get_acl_table_ids(2)
            _, names, _ = self.get_table_stage(dvs_acl, acl_table_id, [], OVERLAY_BIND_PORTS)
            #create 8 rules. 8th one should fail.
            for i in range(1, 9):
                config_qualifiers["DSCP"] = str(i)
                dvs_acl.create_dscp_acl_rule(OVERLAY_TABLE_NAME, str(i), config_qualifiers, action=str(i+10))
                if i < 8:
                    dvs_acl.verify_acl_rule_status(OVERLAY_TABLE_NAME, str(i), "Active")
                else:
                    dvs_acl.verify_acl_rule_status(OVERLAY_TABLE_NAME, str(i), None)
    
>           table_rules = self.get_acl_rules_with_action(dvs_acl, 14)

test_acl_mark.py:434: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test_acl_mark.py:103: in get_acl_rules_with_action
    members = dvs_acl.asic_db.wait_for_n_keys("ASIC_STATE:SAI_OBJECT_TYPE_ACL_ENTRY",
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <dvslib.dvs_database.DVSDatabase object at 0x7f6ec8eb3580>
table_name = 'ASIC_STATE:SAI_OBJECT_TYPE_ACL_ENTRY', num_keys = 14
wait_at_least_n_keys = False
polling_config = PollingConfig(polling_interval=0.01, timeout=20.0, strict=True)
failure_message = None

    def wait_for_n_keys(
        self,
        table_name: str,
        num_keys: int,
        wait_at_least_n_keys: bool = False,
        polling_config: PollingConfig = PollingConfig(),
        failure_message: str = None,
    ) -> List[str]:
        """Wait for the specified number of keys to exist in the table.
    
        Args:
            table_name: The name of the table from which to fetch the keys.
            num_keys: The expected number of keys to retrieve from the table.
            polling_config: The parameters to use to poll the db.
            failure_message: The message to print if the call times out. This will only take effect
                if the PollingConfig is set to strict.
    
        Returns:
            The keys stored in the table. If no keys are found, then an empty List is returned.
        """
    
        def access_function():
            keys = self.get_keys(table_name)
            if wait_at_least_n_keys:
                return (len(keys) >= num_keys, keys)
            else:
                return (len(keys) == num_keys, keys)
    
        status, result = wait_for_result(
            access_function, self._disable_strict_polling(polling_config)
        )
    
        if not status:
            message = failure_message or (
                f"Unexpected number of keys: expected={num_keys}, received={len(result)} "
                f'({result}), table="{table_name}"'
            )
>           assert not polling_config.strict, message
E           AssertionError: Unexpected number of keys: expected=14, received=0 ([]), table="ASIC_STATE:SAI_OBJECT_TYPE_ACL_ENTRY"

dvslib/dvs_database.py:414: AssertionError