[netmod] LL review of draft-yeung-netmod-ospf-02
Ladislav Lhotka <lhotka@nic.cz> Wed, 29 October 2014 09:06 UTC
Return-Path: <lhotka@nic.cz>
X-Original-To: netmod@ietfa.amsl.com
Delivered-To: netmod@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 04C4A1A7001 for <netmod@ietfa.amsl.com>; Wed, 29 Oct 2014 02:06:47 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 2
X-Spam-Level: **
X-Spam-Status: No, score=2 tagged_above=-999 required=5 tests=[BAYES_50=0.8, J_CHICKENPOX_24=0.6, J_CHICKENPOX_44=0.6] autolearn=no
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 ReIm-0VNnN1p for <netmod@ietfa.amsl.com>; Wed, 29 Oct 2014 02:06:45 -0700 (PDT)
Received: from trail.lhotka.name (trail.lhotka.name [77.48.224.143]) (using TLSv1.1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id BC83A1A6FF3 for <netmod@ietf.org>; Wed, 29 Oct 2014 02:06:44 -0700 (PDT)
Received: from localhost (localhost [127.0.0.1]) by trail.lhotka.name (Postfix) with ESMTP id 5CF845408C3 for <netmod@ietf.org>; Wed, 29 Oct 2014 10:06:42 +0100 (CET)
Received: from trail.lhotka.name ([127.0.0.1]) by localhost (trail.lhotka.name [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 1YHhoGuX4h-C for <netmod@ietf.org>; Wed, 29 Oct 2014 10:06:37 +0100 (CET)
Received: from localhost (unknown [195.113.220.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by trail.lhotka.name (Postfix) with ESMTPSA id CDA8C54003C for <netmod@ietf.org>; Wed, 29 Oct 2014 10:06:37 +0100 (CET)
From: Ladislav Lhotka <lhotka@nic.cz>
To: netmod@ietf.org
User-Agent: Notmuch/0.18.1 (http://notmuchmail.org) Emacs/24.4.1 (x86_64-apple-darwin13.4.0)
Date: Wed, 29 Oct 2014 10:06:42 +0100
Message-ID: <m2vbn3ckil.fsf@nic.cz>
MIME-Version: 1.0
Content-Type: text/plain
Archived-At: http://mailarchive.ietf.org/arch/msg/netmod/-LSgd3WX_mxfMhUr0SSd7KaAOH4
Subject: [netmod] LL review of draft-yeung-netmod-ospf-02
X-BeenThere: netmod@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: NETMOD WG list <netmod.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netmod>, <mailto:netmod-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/netmod/>
List-Post: <mailto:netmod@ietf.org>
List-Help: <mailto:netmod-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/netmod>, <mailto:netmod-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 29 Oct 2014 09:06:47 -0000
Hi, I reviewed the OSPF data model and I-D, concentrating mainly on YANG issues and the integration with teh core routing data model. Lada *** General comments The "ospf" module is the result of an intensive cooperation of a multi-vendor expert group. On the one hand, it demonstrates that it is possible to design a YANG module for a relatively complicated routing protocol so as to be applicable to devices of different vendors. On the other hand, it also shows that the need to accommodate disparate configuration logics stemming from each vendor's CLI adds significant complexity to the data model. It is clear that the "ietf-routing" module is a nice fit for the "routing-instance-centric" design but the integration of the "protocol-centric" design is IMO quite awkward. While the (big) vendors participating in the module design may consider the result an acceptable compromise, I suspect it is not that much attractive for those who want to write a new implementation. This is not meant as a criticism of the "ospf" module but rather a reflection of reality that's by no means unique to OSPF. I think it is necessary to evaluate pros and cons of having one complex module that fits all versus multiple concurrent but cleaner modules. *** Module design **** Protocol-centric v. instance-centric model - The dichotomy of protocol-centric and instance-centric models should be better explained in the draft, maybe with examples. - In the protocol-centric case, do all routing protocols (not only OSPF) have to be defined in the default routing-instance? What are then the contents of non-default routing-instances? - References to interfaces use the "if:interface-ref" type, but I think they should always be confined to an appropriate routing-instance, i.e. refer to an entry of /rt:routing-instance/rt:interfaces/rt:interface and not to /if:interfaces/if:interface. **** Inheritance In the "ietf-routing" module, the intent was to have different instances of the same routing protocol as entries of "rt:routing-protocol" list. The "ospf" module models OSPF instances as entries of "rt:routing-protocol/ospf:ospf/ospf:instance". I understand the main purpose of this organization is to allow instances to share data that are defined in "all-instances-inherit". Another way of achieving the same would be to define a special routing protocol type, e.g. "ospf:ospfv2-proto". An instance of this type would be a prototype and its data would be shared by all OSPFv2 instances. The advantages of this are: - parameters that may be inherited can be defined just once, e.g., for "ospf:ospfv2" and "ospf:ospfv2-proto" at the same time. - leafrefs can refer to the same parameter no matter whether it is in the prototype or real instance; - in state data, the prototype instance needn't be present, the inherited parameters will appear as normal parameters of real instances. **** Identities The "ospf:ospfv2" and "ospf:ospfv3" identities are defined with "rt:routing-protocol" as their base. I'd suggest to add a generic "ospf:ospf" identity. Taking into account the previous item, the identity hierarchy could be: rt:routing-protocol ospf:ospf ospf:ospf-proto ospf:ospfv2 ospf:ospfv2-proto ospf:ospfv3 ospf:ospfv3-proto Advantages: - Parameters from the "ospf:ospf" instance could be inherited by *both* OSPFv2 and OSPFv3 instances. - Using the new XPath function "derived-from()" (see sec. 10.4.1 in draft-ietf-netmod-rfc6020bis-01), it will be possible to replace XPath expressions like "rt:type = 'ospf:ospfv2' or rt:type = 'ospf:ospfv3'" with "derived-from(rt:type, "ospf", "ospf")" *** YANG issues - The module should be named "ietf-ospf". - In the definition list neighbor { description "List of neighbors."; leaf neighbor-id { type leafref { path "../../neighbor/neighbor-id"; } description "Neighbor."; } } the "neighbor-id" leafref points to itself. This is is not allowed in YANG, the path should probably be something else. - Several augments have target nodes in the "ospf" module, for example augment "/rt:routing/rt:routing-instance/rt:routing-protocols/" + "rt:routing-protocol/ospf:ospf/ospf:instance" { ... } What is the purpose of doing so? The nodes defined inside such an augment can be put straight under "ospf:instance". Moreover, "when" expressions used for these augments are wrong, for example the above augment has when "../rt:type = 'ospf:ospfv2' or ../rt:type = 'ospf:ospfv3'" but it should be when "../../rt:type = 'ospf:ospfv2'" + "or ../../rt:type = 'ospf:ospfv3'" - some descriptions are extremely terse and should be expanded. *** I-D text - The standard text explaining symbols in tree diagrams should be included. - An example instance document would be helpful, e.g. an extension of the example in appendix D of draft-ietf-netmod-routing-cfg-16. -- Ladislav Lhotka, CZ.NIC Labs PGP Key ID: E74E8C0C
- [netmod] LL review of draft-yeung-netmod-ospf-02 Ladislav Lhotka