Improve memory usage by move ZMQ serialize buffer from ZmqProducerStateTable to ZmqClient #955
Azure Pipelines / Azure.sonic-swss-common
succeeded
Nov 23, 2024 in 5h 52m 37s
Build #20241123.2 had test failures
Details
- Failed: 1 (0.09%)
- Passed: 1,009 (94.48%)
- Other: 58 (5.43%)
- Total: 1,068
- 4402 of 8202 branches covered (53.67%)
- 5052 of 6148 lines covered (82.17%)
Annotations
Check failure on line 1 in test_OverlayEntryTestMetaDataMgr
azure-pipelines / Azure.sonic-swss-common
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 0x7fb361b17a90>
dvs_acl = <dvslib.dvs_acl.DVSAcl object at 0x7fb361b17dc0>
overlay_acl_table = ['oid:0x700000000077d', 'oid:0x7000000000786']
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 0x7fb361a3e0d0>
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
Loading