Re: [core] draft-ietf-core-sid-11: YANG Issues

Ivaylo Petrov <ivaylo@ackl.io> Wed, 11 March 2020 08:51 UTC

Return-Path: <ivaylo@ackl.io>
X-Original-To: core@ietfa.amsl.com
Delivered-To: core@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 16FBD3A1512 for <core@ietfa.amsl.com>; Wed, 11 Mar 2020 01:51:42 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.898
X-Spam-Level:
X-Spam-Status: No, score=-1.898 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=ackl-io.20150623.gappssmtp.com
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 UZMx5TzpwJPi for <core@ietfa.amsl.com>; Wed, 11 Mar 2020 01:51:40 -0700 (PDT)
Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id E8CCC3A1511 for <core@ietf.org>; Wed, 11 Mar 2020 01:51:39 -0700 (PDT)
Received: by mail-wm1-x336.google.com with SMTP id 6so1108928wmi.5 for <core@ietf.org>; Wed, 11 Mar 2020 01:51:39 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ackl-io.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=fyn738te2TiDOkjRl5RLDpKGu9ZB76c5Dl/aTB7ONGo=; b=ZUcKtj1RnIELjnfX3qNTK0I54wwlEn/kJ+eTg1kPJ9clDDLLI5pgiVzbfU4CRbNXOI Q2ablqRM7hD51/Pj2T5GRDnS+mdM9COusgA8Fi5+g62WWo8/tibOt3FqrgKD+VF5FWqg RMK+gNZ2ipiHs3HVN3R7CNbOQqFe0QYKpLhdX04h2neQQ+ynWUcNaY9WWCQ83JEB776F BGHb2/WOPCytDqD/EtxHuZKjak4RbtFZmofPdRhCBXD2NcBG3liAyNwO+wYOKiiU0XgP UwYDg/iDT94T2vI0YddAIXgFl43NX1/EqkUmcDa3Y1MLasfsOACXs9IVcOyCBeCN4x+D tt+w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=fyn738te2TiDOkjRl5RLDpKGu9ZB76c5Dl/aTB7ONGo=; b=gCIG8Zji+uQMKkG/+uGuhRkdlpzwjo3Ez9YNqfg7BYEpqrz6RhJJBXY7WArqMGyEOT b195PV1FT16i6n60tIKdcfts/njtqee0vFyPJaoiaj1w+mnaQjIuK1clogwqQb4lF1iL sDUBI+LSIvPUmURdW0cuWuvEpwm+XrgiYfT7c+m6q9rMtbHddjGJBm2nb9QBP7mhRUfQ ysWYh35SNYNOkOlmto9AEmOIJlchunODf+6e796AlQv9gilOr1tSW6hpeE64/Ro2RQgI /dzoQpnDhfvqVZAq6P34+J+Xk7smF3FYIM115J0JKgDka5wv5PoVHTvysGoGVnsGNZVD YM+w==
X-Gm-Message-State: ANhLgQ03pWkUE9yUHWDAGzLIBT0SXsFgqdFnl1DyBsOXDavWmH3Zn/Zb CBXqStzimJLdjrmrLYEKdrB0qsbsGjyF4CCFeJYK86PN
X-Google-Smtp-Source: ADFU+vscUF393WissAgyVDfbNOmJryHm48vt57zIdvBbofQlZSymv/qZyT0cnz3fkn0mGdRrNlnEmgujbmwd2vBedFo=
X-Received: by 2002:a7b:cd13:: with SMTP id f19mr2724251wmj.10.1583916698090; Wed, 11 Mar 2020 01:51:38 -0700 (PDT)
MIME-Version: 1.0
References: <CABCOCHR5DorvUnY8jDiOVZRsQadU22k2TETdOABGDiiyP-W14w@mail.gmail.com>
In-Reply-To: <CABCOCHR5DorvUnY8jDiOVZRsQadU22k2TETdOABGDiiyP-W14w@mail.gmail.com>
From: Ivaylo Petrov <ivaylo@ackl.io>
Date: Wed, 11 Mar 2020 09:51:11 +0100
Message-ID: <CAJFkdRzmbwsFBU2Ncshm43dFWcL4LS7NTZkPDPNEZGhwafjLMw@mail.gmail.com>
To: Andy Bierman <andy@yumaworks.com>
Cc: Core <core@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000024cfae05a0905859"
Archived-At: <https://mailarchive.ietf.org/arch/msg/core/kJenFeUcLBWUEXRewuowhwbpGXA>
Subject: Re: [core] draft-ietf-core-sid-11: YANG Issues
X-BeenThere: core@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Constrained RESTful Environments \(CoRE\) Working Group list" <core.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/core>, <mailto:core-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/core/>
List-Post: <mailto:core@ietf.org>
List-Help: <mailto:core-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/core>, <mailto:core-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 11 Mar 2020 08:51:42 -0000

Hello, Andy,

Thank you for your review! I believe all your suggestions make sense and
I/we are going to implement them in the following days.

Best regards,
Ivaylo

On Tue, Mar 10, 2020 at 6:05 PM Andy Bierman <andy@yumaworks.com> wrote:

> Hi,
>
> I think this draft is very close but the YANG module still needs some
> changes.
> The JSON example does not match the YANG rc:yang-data definition yet.
> There needs to be a JSON object for the top-level container so the JSON
> conforms to RFC 7951.
>
>
> rc:yang-data sid-file {
>       uses sid-file;
> }
>
> grouping sid-file {
>    container sid-file {
>        // existing YANG objects inserted here
>    }
> }
>
> JSON:
>
> {  "ietf-sid-file:sid-file" : {
>        //  existing JSON objects inserted here
>     }
> }
>
>
> Minor YANG Issues (suggestions)
> 1) move the object definitions to a grouping so they can be reused
> 2) name the container "sid-file" instead of "content"
> 3) change the order of the objects so the "header" fields will be first
>    (module-name, module-revision, sid-file-version)
> 4) consider adding a "description" leaf to the header.  JSON does not
>    support comments or annotations, but this JSON file is really intended
>    to be used by automation tools.  IMO, JSON is not a very good choice
>    as a source code document, but a description string can help a little.
>   It can also contain extra metadata such as the SID file creation time.
>
>
> Andy
>
> _______________________________________________
> core mailing list
> core@ietf.org
> https://www.ietf.org/mailman/listinfo/core
>