-
Notifications
You must be signed in to change notification settings - Fork 107
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
Diff api does generate deletes for leaf list values #933
Comments
Hi, ygot.Diff returns a Notification value. What did you do with the Notification value that caused the final list to occur? |
I used the notification list to update device config. In the notification list, there is an update for [18, 25, 34] but no delete is generated for value 1 in the leaf list |
Did you use gNMI.Set with an That being said, taking a look at RFC7950, NETCONF insert seems to offer more flexible operations, while the gNMI spec doesn't explicitly talk about this scenario. @robshakir Do we have a stance on what happens with leaf-lists when gNMI.Set with |
Yes, we do not allow partial update of leaf-lists in gNMI -- we declaratively require them to be entirely specified. |
In this case, can I enhance the ygot diff api to return a replace gnmipb.Update slice along side the gnmi notification to be used together for the gnmi set request? |
Not quite sure what enhancement you had in mind. Can you just call Set.Replace now instead of Set.Update? It seems like the device is not conforming to the right spec (I will make a PR to update the spec soon), and since Diff only returns leaves it seems like a safe thing to do. |
I changed a leaf list value from [1, 18, 25] to [18, 25, 34]. Ygot diff api generate an update with value [18, 25, 34] and no delete. This results in the final list of [1, 18, 25, 34] which is not expected.
The text was updated successfully, but these errors were encountered: