Subject: [netmod] AD review draft-ietf-netmod-yang-metadata-03

From: Benoit Claise <[email-masked]>
Date: Wed, 24 Feb 2016 10:34:36 +0100

Dear all,

Here is my AD review of draft-ietf-netmod-yang-metadata-03. Only 
editorial comments, except potentially the last point.

-
"data type", to which you refer in the terminology section, is not defined in
[I-D.ietf-netmod-rfc6020bis 
<https://tools.ietf.org/html/draft-ietf-netmod-yang-metadata-03#ref-I-D.ietf-netmod-rfc6020bis>] terminology section.

-
    "An annotation MUST NOT change the data tree semantics defined by
    YANG."

We should be consistent between YANG modules versus YANG models versus YANG data models versus YANG.
See my previous message on the list.
Here I believe we need:
    "An annotation MUST NOT change the data tree semantics defined by
    the YANG module".

-
OLD:
Copyright (c) 2015 IETF
NEW:
Copyright (c) 2016 IETF

-
        The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL
         NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'MAY', and
         'OPTIONAL' in the module text are to be interpreted as described
         inRFC 2119 <https://tools.ietf.org/html/rfc2119>  (http://tools.ietf.org/html/rfc2119).

This language in the YANG module is certainly a left over the draft version 1. I don't see any RFC2119 in the module itself.

-
"The 'md:annotation' statement can appear only at the top level of a YANG module."

I don't understand what the top is? You mean, after the import statements.
Should pyang check this? If yes, how?
 From the example,

        The following module defines the "last-modified" annotation:

        module example-last-modified {
          namespace"http://example.org/example-last-modified";
          prefix "elm";
          import ietf-yang-types {
            prefix "yang";
          }
          import ietf-yang-metadata {
            prefix "md";
          }
          md:annotation last-modified {
            type yang:date-and-time;
            description
              "This annotation contains date and time when the
               annotated instance was last modified (or created).";
          }
        }

Regards, Benoit

---

From: Juergen Schoenwaelder <[email-masked]>
Date: Wed, 24 Feb 2016 11:16:15 +0100

On Wed, Feb 24, 2016 at 10:34:36AM +0100, Benoit Claise wrote:

[...]

> Should pyang check this? If yes, how?

I think the intention was to say at the 'top-level of the schema tree'.
It does not have to be right after the imports.

/js

-- 
Juergen Schoenwaelder           Jacobs University Bremen gGmbH
Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
Fax:   +49 421 200 3103         <http://www.jacobs-university.de/>

---

From: Benoit Claise <[email-masked]>
Date: Wed, 24 Feb 2016 11:27:33 +0100

> It does not have to be right after the imports.
That would clarify. Thanks.

Regards, Benoit

---

From: Ladislav Lhotka <[email-masked]>
Date: Wed, 24 Feb 2016 12:30:46 +0100

Hi Benoit,

thanks for the review, please see my replies inline.

> On 24 Feb 2016, at 10:34, Benoit Claise <[email-masked]> wrote:
> 
> Dear all,
> 
> Here is my AD review of draft-ietf-netmod-yang-metadata-03. Only editorial comments, except potentially the last point.
> - 
> ] terminology section.

The term "data type" certainly is defined in 6020bis, albeit not in the terminology section.

>    "An annotation MUST NOT change the data tree semantics defined by

Actually, I think "YANG" is correct here, meaning "YANG the data modelling language". For example, an annotation cannot mean "this configuration list has no keys" because YANG specification doesn't allow it. This rule is written in 6020(bis), not in any YANG module.

> Copyright (c) 2016 IETF

OK, will fix, and also add Lou as the third WG chair.

>         in 
> RFC 2119 (http://tools.ietf.org/html/rfc2119
> ).
> 

Right, I will remove this text from the module. 

> I don't understand what the top is? You mean, after the import statements.

What is means is "not inside definition of schema nodes." I will add such a clarification.

> Should pyang check this? If yes, how?

Yes, pyang could check it when parsing a module. The "dsdl" translator ignores this annotation unless it is at the top level.

Thanks, Lada

>      namespace 
> "http://example.org/example-last-modified"
> ;
>      prefix "elm";
>      import ietf-yang-types {
>        prefix "yang";
>      }
> _______________________________________________
> netmod mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/netmod

--
Ladislav Lhotka, CZ.NIC Labs
PGP Key ID: E74E8C0C

---

From: Ladislav Lhotka <[email-masked]>
Date: Wed, 24 Feb 2016 12:34:19 +0100

> On 24 Feb 2016, at 11:16, Juergen Schoenwaelder <[email-masked]> wrote:
> 

To my understanding, these declarations aren't part of the schema tree.

Lada

---

From: Juergen Schoenwaelder <[email-masked]>
Date: Wed, 24 Feb 2016 12:44:47 +0100

> To my understanding, these declarations aren't part of the schema tree.

OK. Perhaps it is most precise to refer to the ABNF productions where
the annotation can appear, e.g., it is 'inside the body-stmts'.

/js