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

Ignore ref counts when deleting DASH objects #1536

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

theasianpianist
Copy link
Contributor

@theasianpianist theasianpianist commented Feb 19, 2025

As per the DASH HLD, we need to be able to delete certain 'parent' SAI objects even when they are still referenced: https://github.com/sonic-net/SONiC/blob/master/doc/dash/dash-sonic-hld.md#18-implicit-deletion-of-sai-objects

E.g. A DASH_OUTBOUND_ROUTING_GROUP may be referenced by one or more DASH_OUTBOUND_ROUTING_ENTRIES. We should be able to delete DASH_OUTBOUND_ROUTING_GROUPS even if related routing entries still exist. The SAI implementation will implicitly delete all routing entries when the routing group is deleted, which is why we need to ignore reference count for these specific objects when validation removal.

@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Signed-off-by: Lawrence Lee <[email protected]>
@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@kcudnik
Copy link
Collaborator

kcudnik commented Feb 19, 2025

this seems like a bad idea and in long run it will cause crash and inconsistency, please provide description

@theasianpianist
Copy link
Contributor Author

this seems like a bad idea and in long run it will cause crash and inconsistency, please provide description

Updated description

@kcudnik
Copy link
Collaborator

kcudnik commented Feb 20, 2025

i dont quite understand, that you can request to delete all entries even if they are still in use, this will definitely cause inconsistency error, since some attributes will still have attributes SET to that value you deleted, and this will cause in long rung syncd to crash because of inconsistency and reference count error.

The change you are making is not solving actual issue, its one step to collapse everything, later on you will have to make changes in syncd and allow to remove objects which are in use and you will have no choice to crash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants