-
Notifications
You must be signed in to change notification settings - Fork 13
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
Use of binary types where well known yang/ietf types should be used #23
Comments
I see what you mean.
This is an internal data representation. |
Any application designed to work with ODL or another yang based system
will expect to work with an address as per the IETF model representations.
While the internal representation is usually binary the interchange is
always the textual one.
I have a workaround for it at present - I am presenting "hacked" models
to ODL which have all MAC and IP addresses as per IETF notation. At the
same time I am loading the ip address parser into CPS as shown in the
example on the wiki. As a result I get it to work correctly end-to-end.
However, in the long term, I do not think that having two different
models - one for presenting and one for internal use is viable. There is
a risk that they may get out of sync.
A.
…On 09/03/18 20:18, Rakesh Datta wrote:
I see what you mean.
*
ietf-yang-type is defining it mac-address as:
type string {
pattern '[0-9a-fA-F]{2}(:[0-9a-fA-F]{2}){5}';
}
*
OPS is defining it mac-address as:
type binary {
length "6";
}
Can u plz elaborate, with example, what interop issues are you facing?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#23 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ALkzWOw9KgSSf36yqnBJraf9Ctu6LSO8ks5tcuOdgaJpZM4Sj4lU>.
|
Hi Anton, I did dig deeper into it and I agree with your point. From inter-op perspective, It's always ideal to use the IETF-defined types. However, there are numerous integrations with OPX, that require these types to be customized. That's why we had to define it in the most general and simplest form, i.e. binary. This is a pure design decision. Modifying these types is not feasible in the next release, because it would need a wide-spread churn. Thanks |
Hi @kot-begemot-uk I am re-evaluating this issue now. To present the case better can you please provide all the information mentioned here: https://github.com/open-switch/opx-docs/wiki/Report-bugs |
Present in all versions. The following elements in dell-base-common.yang are incompatible with all known upstream yang implementations because they are in violation of RFC6021 which clearly determines what their representations should be for interchange purposes. typedef mac-address { typedef ipv6-address { typedef ip-address { |
What is the problem you are reporting - Fundamental design fault |
All models use binary blobs for ip addresses and macs. There is a set of types defined in the ietf-types and ietf-yang-types models imported by OPX which should be used in order to interoperate with any other yang based system.
The text was updated successfully, but these errors were encountered: