Comments (6)
Hi, ygot.Diff returns a Notification value. What did you do with the Notification value that caused the final list to occur?
from ygot.
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
from ygot.
Did you use gNMI.Set with an Update
message? If so, I believe setting a leaf-list should overwrite the value instead of appending to them.
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 Update
is executed? Since we don't have an insert operation it seems like replacement must be our behaviour to keep things simple? Esp. if a non-leaf update is made containing leaf-list values. If so I'll update the spec to make this clearer.
from ygot.
Yes, we do not allow partial update of leaf-lists in gNMI -- we declaratively require them to be entirely specified.
from ygot.
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?
from ygot.
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.
from ygot.
Related Issues (20)
- `slices.SortFunc`'s `cmp` function uses wrong return type HOT 2
- Make sure CI runs `go mod tidy` and notices no diffs.
- ygot.diff seems slow
- ytypes.GetNode consumes more CPU & memory than the deprecated util.GetNode
- how to resolve the dependency for gribi HOT 2
- Can enum preserve their defined values while converting yang to gostruct using openconfig/ygot\@v0.25.4/generator/generator.go ? HOT 3
- ygot.Diff don't respect presence containers HOT 8
- Mandatory module name in the generated struct names HOT 3
- Preserve YANG elements order when generating structs HOT 1
- Doesn't choice and case statement in YANG result in oneof fields in proto? HOT 2
- ygot Validate error, when yang leaf type is union
- When will ygot have support for bits datatype for yang to go conversion HOT 2
- Device Returns Array for Each Interface HOT 3
- Allow ytypes.SetNode on intermediate nodes in compressed mode
- Identity Support in Ygot HOT 1
- Union field has nil value after xml.Unmarshal HOT 5
- [Question] From ygot gostruct or emittedJSON to gNMI Set Update HOT 6
- ytypes.Unmarshal() treating 50 as a float64 even though I am converting 50 to string before unmarshalling HOT 5
- How to set LeafrefOptions IgnoreMissingData for UnmarshalSetRequest HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ygot.