-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
operational-state (datastore) change notifications #17796
operational-state (datastore) change notifications #17796
Conversation
d9ed722
to
dc66226
Compare
d8c15b9
to
94fe28d
Compare
66e4ed0
to
275b1e0
Compare
|
||
nb_notif_add(abs_path); | ||
|
||
if (abs_path != path) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the chance that abs_path and path are equal and path was passed in?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
abs_path
starts out assigned as NULL
, it is then either assigned the value path
or it is a new allocation from lyd_path()
. path
is not currently allowed to be NULL (notice we use path[0]
without checking for path == NULL
). So path can only ever equal abs_path
when we set it that way (which is what our equality check is deciding, did we set it or newly allocate it).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That said, I don't see a reason we couldn't also support a NULL path for updating the path/value of the tree node itself, so I'll modify the code to also handle path == NULL.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually nm, this gets tricky deeper in the implementation, i'll leave extended functionality for later if we need it.
26f0f0a
to
f9eac62
Compare
Signed-off-by: Christian Hopps <chopps@labn.net>
Signed-off-by: Christian Hopps <chopps@labn.net>
Signed-off-by: Christian Hopps <chopps@labn.net>
Signed-off-by: Christian Hopps <chopps@labn.net>
- Additionally push the selectors down to the backends Signed-off-by: Christian Hopps <chopps@labn.net>
Signed-off-by: Christian Hopps <chopps@labn.net>
Signed-off-by: Christian Hopps <chopps@labn.net>
f9eac62
to
c88b489
Compare
mgmtd backend yang model (depends on #17796)
Add framework for notifications sent to front-end clients for changes to operational state (datastore). This is to support various YANG push RFCs such as: