[acl] Refactor port OID retrieval into aclorch#1462
Merged
daall merged 1 commit intosonic-net:masterfrom Oct 14, 2020
Merged
Conversation
Signed-off-by: Danny Allen <[email protected]>
Contributor
Author
|
retest vs please |
Contributor
Author
|
retest vs please |
lguohan
approved these changes
Oct 13, 2020
Contributor
|
retest vs please |
1 similar comment
Contributor
Author
|
retest vs please |
3 tasks
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
Janetxxx
pushed a commit
to Janetxxx/sonic-swss
that referenced
this pull request
Nov 10, 2025
Signed-off-by: Danny Allen <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Signed-off-by: Danny Allen [email protected]
What I did
I moved getAclBindPortId from portsorch to aclorch.
Why I did it
This serves two purposes:
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_updatepytest because it deletes the PortChannel at the end of the test case, which triggers a delete event, which triggers this bug.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
TODOindicating the same.How I verified it
test_po_updatepasses in the master image now. I also re-ran theaclandeverflowtests and everything looks good to go.Details if related
Fixes sonic-net/sonic-buildimage#5273