[lisp] YANG data models in LISP: extraction and compilation feedback

Benoit Claise <bclaise@cisco.com> Fri, 11 December 2015 13:03 UTC

Return-Path: <bclaise@cisco.com>
X-Original-To: lisp@ietfa.amsl.com
Delivered-To: lisp@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id B3FAD1A8A96; Fri, 11 Dec 2015 05:03:02 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -14.509
X-Spam-Level:
X-Spam-Status: No, score=-14.509 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5, T_RP_MATCHES_RCVD=-0.01, USER_IN_DEF_DKIM_WL=-7.5] autolearn=ham
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id HPAUW6K9hxHM; Fri, 11 Dec 2015 05:03:00 -0800 (PST)
Received: from aer-iport-1.cisco.com (aer-iport-1.cisco.com [173.38.203.51]) (using TLSv1.2 with cipher DHE-RSA-SEED-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 932651A8A9E; Fri, 11 Dec 2015 05:02:59 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=8539; q=dns/txt; s=iport; t=1449838980; x=1451048580; h=to:from:subject:cc:message-id:date:mime-version; bh=41DCR/r+RkB97rQ+LZfsD/JQdGDTU1RxIBzj3Cg2aco=; b=jGtkwHii61Nwqkd+INwtKnGfqwqxvsLOyetKt9GsVJ5BHYRtac3MFdfJ E/xEmbQaCcdBgrMUcpPZm8XZz33Rmus6cAgwYZqeSH2V/b3U8vtXGIgB0 cMaOagWek/raXUgmPTTVyZoY0UywVd9yMLtGtmftuNA8l+b3RMnZ019vH Y=;
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: A0DOAQBoyGpW/xbLJq1ehA1uuxaCGQENgWIXAQuFbIFoFAEBAQEBAQGBCoQ3JyYwPCECEQJZBgIBAYgrDaxPkgEBAQEHAQEBAQEehlaJP0aCNToTgTYFjTOJP4U1iA+BW0mHAY94g3MfAQFChAU9NAGFVgEBAQ
X-IronPort-AV: E=Sophos;i="5.20,413,1444694400"; d="scan'208,217";a="633691100"
Received: from aer-iport-nat.cisco.com (HELO aer-core-1.cisco.com) ([173.38.203.22]) by aer-iport-1.cisco.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 11 Dec 2015 13:02:57 +0000
Received: from [10.60.67.86] (ams-bclaise-8915.cisco.com [10.60.67.86]) by aer-core-1.cisco.com (8.14.5/8.14.5) with ESMTP id tBBD2uT3028742; Fri, 11 Dec 2015 13:02:56 GMT
To: lisp@ietf.org
From: Benoit Claise <bclaise@cisco.com>
Message-ID: <566AC980.10909@cisco.com>
Date: Fri, 11 Dec 2015 14:02:56 +0100
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0
MIME-Version: 1.0
Content-Type: multipart/alternative; boundary="------------070601090605050801030805"
Archived-At: <http://mailarchive.ietf.org/arch/msg/lisp/cyF_9ssE3lDmFs18wwlVFf6-6bI>
Cc: draft-ietf-lisp-yang@ietf.org, "yang-coord@ietf.org" <yang-coord@ietf.org>
Subject: [lisp] YANG data models in LISP: extraction and compilation feedback
X-BeenThere: lisp@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: List for the discussion of the Locator/ID Separation Protocol <lisp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/lisp>, <mailto:lisp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/lisp/>
List-Post: <mailto:lisp@ietf.org>
List-Help: <mailto:lisp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/lisp>, <mailto:lisp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 11 Dec 2015 13:03:02 -0000

Dear all,

I looked at the YANG model in the LISP WG document, from a compilation 
point of view (NOT a YANG design point of view):
https://tools.ietf.org/html/draft-ietf-lisp-yang-00

First of, we can't extract your YANG models from the draft.

Here are the extraction error messages:
xym.py draft-ietf-lisp-yang-00.txt
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 138 - Yang module 'ietf-lisp' 
with no <CODE BEGINS> and not starting with 'example-'
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 1193 - Yang module 'lisp-itr' 
with no <CODE BEGINS> and not starting with 'example-'
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 1630 - Yang module 'lisp-etr' 
with no <CODE BEGINS> and not starting with 'example-'
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 2363 - Yang module 
'lisp-map-server' with no <CODE BEGINS> and not starting with 'example-'
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 2638 - Yang module 
'lisp-map-resolver' with no <CODE BEGINS> and not starting with 'example-'
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 3291 - Yang module 
'lisp-pitr' with no <CODE BEGINS> and not starting with 'example-'
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 3548 - Yang module 
'lisp-petr' with no <CODE BEGINS> and not starting with 'example-'
ERROR: 'draft-ietf-lisp-yang-00.txt', Line 3651 - Yang module 
'lisp-address-types' with no <CODE BEGINS> and not starting with 'example-'

As mentioned in 
https://tools.ietf.org/html/draft-ietf-netmod-rfc6087bis-05, the correct 
way to use <CODE BEGINS> <CODE ENDS> is

    The "<CODE BEGINS>" tag SHOULD be followed by a string identifying
    the file name specified in Section 5.2 of
    [I-D.ietf-netmod-rfc6020bis 
<https://tools.ietf.org/html/draft-ietf-netmod-rfc6087bis-05#ref-I-D.ietf-netmod-rfc6020bis>].  The following example is for the
    '2010-01-18' revision of the 'ietf-foo' module:

      <CODE BEGINS> file"ietf-foo@2010-01-18.yang"
        module ietf-foo {
          // ...
          revision 2010-01-18 {
            description "Latest revision";
            reference "RFC XXXX";
          }
          // ...
        }
      <CODE ENDS>


Note that the example YANG models should use the "example-" prefix, and 
no <CODE BEGINS> <CODE ENDS>


Now, if I extract those modules anyway, you have some compilation errors:
pyang --ietf *.yang
lisp-address-types.yang:1: warning: RFC 6087: 4.1: the module name 
should start with one of the strings "ietf-" or "iana-"
lisp-etr.yang:1: warning: RFC 6087: 4.1: the module name should start 
with one of the strings "ietf-" or "iana-"
lisp-itr.yang:1: warning: RFC 6087: 4.1: the module name should start 
with one of the strings "ietf-" or "iana-"
lisp-map-resolver.yang:1: warning: RFC 6087: 4.1: the module name should 
start with one of the strings "ietf-" or "iana-"
lisp-map-server.yang:1: warning: RFC 6087: 4.1: the module name should 
start with one of the strings "ietf-" or "iana-"
lisp-petr.yang:1: warning: RFC 6087: 4.1: the module name should start 
with one of the strings "ietf-" or "iana-"
lisp-pitr.yang:1: warning: RFC 6087: 4.1: the module name should start 
with one of the strings "ietf-" or "iana-"

Once you correct the extraction issues, the YANG models, along with some 
remaining compilation errors, will appear at 
http://www.claise.be/IETFYANGPageCompilation.html

Finally, note that www.yangvalidator.com is your friend._
_
Regards, Benoit