-
Notifications
You must be signed in to change notification settings - Fork 88
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
gnmi on-change clarification #219
base: master
Are you sure you want to change the base?
Conversation
Clarification in 3.5.1.5.2 On Change for counter type exclusion and heartbeat behaviors.
Update gnmi-specification.md
Could you elaborate on the reasoning for this change? It seems that the scenario you have in mind is already covered by the target defined mode: reference/rpc/gnmi/gnmi-specification.md Lines 1634 to 1640 in 95392c1
I don't agree that this can be considered "a clarification". This is a significant change in the behavior.
What's the definition of a "rapidly changing counter type"? How can it be distinguished from other counter types? |
The reasoning is that TARGET_DEFINED is left to the vendor to determine the best type of subscription. Comparison of vendor implementations have shown a difference in view of which type of subscription should be used. The use of ON_CHANGE avoids the ambiguity and vendor implementation for type of subscription. The current ON_CHANGE description does not indicated the behavior if there is a mix between leaves suitable for event based update and counters. For example an ON_CHANGE subscription to /interfaces/interface/state would include the counter container within the hierarchy. The counter performance leaves are only desired on SAMPLE basis. This is an obvious scenario, but in some cases there is no counter container and some mix of event leaf and counter items are present within the same container. Some vendors already behave as described while others do not provide ability to subscribe with ON_CHANGE as a result and have create issues with their choice of implementation of type of subscription with TARGET_DEFINED. Changing in wording to remove rapidly is fine to cover any counter that should be sample based. |
What do you mean by that? IMO, the current definition of on_change is straightforward and unambiguous: there are no cases where an implementation can switch to another mode implicitly.
In many cases, yes, This is when you should use SAMPLE or TARGET_DEFINED to subscribe :-)
And in that case target_defined works well, if one has a good implementation.
I disagree with that idea as well. Your proposal eliminates the ability to use a true ON_CHANGE mode for counters. There are legitimate use cases for this functionality; even if it might not apply to your use case. In my view, you should be looking to add a new subscription mode if you want to have this implemented properly and have a solid argument as to why TARGET_DEFINED is not sufficient. The current proposal is a non-backward compatible change to the definition of the ON_CHANGE, and that's not great. |
Provide clarification to On Change for STREAM Subscription in section 3.5.1.5.2 to exclude rapidly changing counter types and only stream updates on the initial subscription and at the heartbeat interval if it has been specified.