-
Notifications
You must be signed in to change notification settings - Fork 74
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
Support for DELETE obejct on list level #55
Comments
DELETE is and SHOULD only be applicable on leafs/leaf-list. DELETE roughly corresponds to the no command , where you set the value of a leaf/leaf-list to it's default value (or erase the value completel) The update operation SHOULD NOT be used to delete list items or presence containers . The name DELETE might be a misnomer here . Where is this requirement coming from?? |
Coming from a demo script. The user want to delete all items in a list, and try to assign a DELETE object for an instance of python class generated by list statement. Checked the use example in rfc 6241:
thought this would be a reasonable use case. We might need to add documentation for DELETE object? |
I think Manu is correct that we shouldn't be doing a delete as part of an update. We discussed this extensively while refining the semantics of the CRUD service. If we want to combine update, create and delete in a single operation, then what we need to have is a "NETCONF Service". |
Great, then we will close this issue. And the user should use NETCONF service if the combination of create, delete and update is needed in a single operation. |
Background
Currently the DELETE object supports deletion on leaf and container level for CRUD update operation, which provide user with flexibility to delete and create attribute at the same time. However we lack the support for using DELETE object on list.
Proposal
We could add an attribute or property
_delete
on python class created from list statement, and with this attribute being set as DELETE object, we could provide user the capability to delete list element with specified list key. For example,CRUD update operation on bgp_cfg will delete this ipv6 afsf and create ipv4 afsf.
The text was updated successfully, but these errors were encountered: