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] Refactor port OID retrieval into aclorch #1462

Merged
merged 1 commit into from
Oct 14, 2020

Conversation

daall
Copy link
Contributor

@daall daall commented Oct 9, 2020

Signed-off-by: Danny Allen daall@microsoft.com

What I did
I moved getAclBindPortId from portsorch to aclorch.

Why I did it
This serves two purposes:

  1. There was a bug wherein AclTable::update would fail to handle port deletion events because the getAclBindPortId method lived in portsorch. Because this method was using the provided alias to get the OID internally, this method would fail in the delete case because the port had already been deleted from portsorch. As a result, all delete events would fail and print a "Unable to retrieve OID" method. This was caught by the test_po_update pytest because it deletes the PortChannel at the end of the test case, which triggers a delete event, which triggers this bug.

  2. The behavior implemented in this method is specific to the ACL implementation in SONiC, and it doesn't really make sense to include it in the more generic AclOrch. Furthermore, we have access to all the port info in AclOrch, so there is no need to take a dependency on PortsOrch to fetch the port OID info and perform the parsing logic. There was a TODO indicating the same.

How I verified it
test_po_update passes in the master image now. I also re-ran the acl and everflow tests and everything looks good to go.

Details if related
Fixes sonic-net/sonic-buildimage#5273

Signed-off-by: Danny Allen <daall@microsoft.com>
@daall
Copy link
Contributor Author

daall commented Oct 12, 2020

retest vs please

@daall daall requested a review from lguohan October 12, 2020 20:51
@daall
Copy link
Contributor Author

daall commented Oct 13, 2020

retest vs please

@lguohan
Copy link
Contributor

lguohan commented Oct 13, 2020

retest vs please

1 similar comment
@daall
Copy link
Contributor Author

daall commented Oct 13, 2020

retest vs please

@daall daall merged commit dbafaad into sonic-net:master Oct 14, 2020
@daall daall deleted the acl_update_fix branch October 14, 2020 05:12
EdenGri pushed a commit to EdenGri/sonic-swss that referenced this pull request Feb 28, 2022
- What I did
Support new Mellanox system SN4600

- How I did it
Add the system name to the buffer migration script even if the system is first added
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

test_po_update flaky on KVM
2 participants