Re: [netmod] yang versioning solution complexity and alternative approaches

Andy Bierman <andy@yumaworks.com> Wed, 09 March 2022 18:13 UTC

Return-Path: <andy@yumaworks.com>
X-Original-To: netmod@ietfa.amsl.com
Delivered-To: netmod@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 2428D3A1083 for <netmod@ietfa.amsl.com>; Wed, 9 Mar 2022 10:13:01 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.898
X-Spam-Level:
X-Spam-Status: No, score=-6.898 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5, SPF_HELO_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_PERMERROR=0.01] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=yumaworks-com.20210112.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 vketMUMsNfWZ for <netmod@ietfa.amsl.com>; Wed, 9 Mar 2022 10:12:56 -0800 (PST)
Received: from mail-yw1-x1135.google.com (mail-yw1-x1135.google.com [IPv6:2607:f8b0:4864:20::1135]) (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 0F3F93A109F for <netmod@ietf.org>; Wed, 9 Mar 2022 10:12:55 -0800 (PST)
Received: by mail-yw1-x1135.google.com with SMTP id 00721157ae682-2dc28791ecbso32574197b3.4 for <netmod@ietf.org>; Wed, 09 Mar 2022 10:12:55 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yumaworks-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=2qmWD/SE0jXrrTGvz9tj4QIPtwegZu3GHufr6HqAdZ8=; b=ELVQ59dPYkzOiZu/GS0Xu6RBcNq2QypmkaRyiHGzPF2cNyvOdzTyUvHDMoYmEKsiWQ k/seiNd9aJAq90ExXPbUBr5bqYjLQ+MAjCWH95yQwX4QXGXCecqOD0mSy8IY3Uaketzz wdenUYYXc8b+wJfeKoWX55jBSfAOH2peZ+CwwliM6ZYuBY6yyRyt2OzoQWc2+GlqanMY eBuWpnNF89w2uNWE5veNAxHHgK4zlR8D2tmWVG/1S55Xlg6NwiGXBCIJ8MpcH6R7LrSn zzyFyzd+G9O3TWuGXe3bvSEwNCfm+wXIPuyFY6VbZyRK7rs0nmGyVndy5ecwFaF3d1Q5 KzTw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=2qmWD/SE0jXrrTGvz9tj4QIPtwegZu3GHufr6HqAdZ8=; b=rBP+Ikgh0pV7ghLeYwY2sJs76mTd8UnBDmnGNfkgtzp9qI5fWsNIBrmA9IYe9w07PO Fls225hFuYohmQrpQF7JwgLBL0vzoU/11OeOYpcAoyYlnPNw3UaX/9bHwksjCtPWEPdE 1MIvR2efSPCHVWVoagtWZpNaxFDnv42RM2/fJB9b+AtzBJ9ZvF6DCjVUrO+YY+hfJ4r/ 1zw8VPoWsUCQqO5ZDVm/ULJNuu3geEfUVWRVF6CCAWu0IDoXqfr8D1DknlTozvlnMXZx Dih1vpC8xvLjpzcDlMNBQORDvARh6C7U0QM7qHWhgiAxdWxYqMshRjwqhBHnRwV/Bfnw uTSQ==
X-Gm-Message-State: AOAM532uhhKH4JG3FklkcvBf8UCLl/xoyrru8JUSK9oQHwDC0qPvdfEO TnIQgr1I3eUSTDa2MXXHGyNnwFP6/TQOBLn1GOLCRQ==
X-Google-Smtp-Source: ABdhPJy2Z4qz46OmvIfGtS9b9PdLrAOIsn9L6jjOPFBu3lr0OBpELWjOQ7+PcXhMOS8q+U4i/pnOkqg1IHjpSSheR6c=
X-Received: by 2002:a81:7189:0:b0:2dc:53e2:88bb with SMTP id m131-20020a817189000000b002dc53e288bbmr949425ywc.110.1646849574525; Wed, 09 Mar 2022 10:12:54 -0800 (PST)
MIME-Version: 1.0
References: <20220309101609.d33knxlhyq62wejq@anna>
In-Reply-To: <20220309101609.d33knxlhyq62wejq@anna>
From: Andy Bierman <andy@yumaworks.com>
Date: Wed, 09 Mar 2022 10:12:43 -0800
Message-ID: <CABCOCHSPScMQKpdeqV0-D+DNyPdWwkb0O7eXT1TZDiztp48oYA@mail.gmail.com>
To: Jürgen Schönwälder <j.schoenwaelder@jacobs-university.de>, NetMod WG <netmod@ietf.org>
Content-Type: multipart/alternative; boundary="000000000000e371bd05d9cd0b2c"
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/hTS6Su4fb1pAj1qr3MsPXsO7-8g>
Subject: Re: [netmod] yang versioning solution complexity and alternative approaches
X-BeenThere: netmod@ietf.org
X-Mailman-Version: 2.1.29
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: <https://mailarchive.ietf.org/arch/browse/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, 09 Mar 2022 18:13:01 -0000

On Wed, Mar 9, 2022 at 2:16 AM Jürgen Schönwälder <
j.schoenwaelder@jacobs-university.de> wrote:

> Hi,
>
> the YANG versioning solution appears to be complex.
>
>
strongly agree.

There are many new procedures (for using extensions) that are not likely to
be adopted outside of the IETF/

There was a valid original problem statement related to release trains.
This is the first disconnect. The problem is related to software release
trains.
Vendors do not release YANG modules. The release software that contains and
implements YANG modules.

Multiple release trains can lead to 2 problems (that are currently handled
by the implementation)

1) most recent release date for a module may not be the latest in all
software release trains
    This affects "import-without-revision" for a client that tries to use
the most recent revision

2) the same [name, date] tuple may be used in multiple release trains.
   This affects the YANG library and <get-schema>.

The solution for (1) is problematic because extensions are used and a YANG
1.1 compliant
tool MAY ignore ANY extension. I support a better import-stmt, but this
should be
done in a new YANG version so it is not optional to implement.

The solution for (2) is not workable (as pointed out, it could take 5 days
to release a change),
and the different revision dates add complexity and do not work if
import-by-revision is used.

A great deal of effort is spent identifying that an NBC change occurred.
IMO it is not useful at the module level.  It would be useful at the object
level,
but at a significant module maintenance cost.




> - We introduce version numbers that smell a bit like SemVers but then
>   are not really SemVer.
>
>

This is very important.
IMO it will do harm to interoperability to have 2 SemVer schemes in use.
The early drafts said the OpenConfig SemVer 2.0 would be used.



> - We have no solution to do meaningful things with these version
>   numbers, it does not even seem to be possible to decide whether
>   X.Y.Z derives from x.y.z or not. We still seem to believe that
>   having compatibility constraints embedded in module imports are a
>   workable solution even though we acknowledge future breaking
>   changes.
>


We have no plans whatsoever to write code that uses the NBC extensions.
The module revisions have to be compared and the real changes have to
be evaluated against real use-cases and real applications.  Since the
tooling
has to do all the work anyway, having a "this module changed" flag is not
really useful.



>
> - We push for a reasonably complex algorithm to calculate deltas of
>   YANG module revisions to let users of modules to determine the real
>   impact of module updates on their work.
>
>

The semver is trying to characterize changes to the YANG module and also
seems to try to identify the software release train containing the module.

I wonder why we not consider the opposite approach, namely to have
> author making NBC changes to document them right where the changes
> are. If authors would write something like
>
>       leaf foo {
>         nbc-change "2022-03-01" {
>           description "changed type from int32 to string";
>         };
>         // ...
>       }
>
>

This is more work but also more useful.

I am confused about the revision updates for work-in-progress.
IMO there SHOULD NOT be any revision tracking from I-D to I-D.
This would be total noise and way too much work.
Consider the client-server groupings, which had constant NBC changes
across 27 revisions of the drafts.

I-Ds currently reuse the same revision-stmt over and over in an update I-D,
just changing the date.  Maintaining a semver label throughout this process
is a waste of time.

There is also no way to tell that a 1.x.x release is a work-in-progress.
It is clear for 0.x.x  only.

There is no easy way to identify a release as "published" or "unpublished",
especially since YANG modules are extracted from the source document.





> then tool and humans can easily figure out in which revision NBC
> changes occured and if they affect a certain usage of the module.
>
> Instead of simply properly documenting the changes, we invent fuzzy
> version numbers and complex algorithms to reverse engineer the facts
> that could have easily been documented by whoever makes the change.
>

Some vendors actually avoid making NBC changes to their APIs.
IMO this IETF work is trying to normalize bad engineering practice.
The past WG (people creating YANG 1.0 and YANG 1.1) felt quite strongly
that changing the type of a leaf was something that should not be allowed.


> If the reason is that developers do not document their changes, then
> go and develop tools to force them to document their changes. I do not
> think it is fair to simply push the pain to the users of YANG modules.
>
>

1 more comment:

Errata not integrated:

Most organizations publish corrected documents when mistakes are found, but
not the IETF.
Instead the WEB page will have a link "Errata Exists".  It is up to the
reader to notice it,
read all the errata, apply all the changes manually, and maintain their own
private copy
of the RFC.

This is especially bad for extracted YANG modules.
For example there is no way to create a revision label (or date string) that
indicates that this is  [ietf-netconf-notifications, 2012-02-06] + Errata
3957.
Vendors just hack the incorrect RFC version of the module.
It would be quite useful to have corrected YANG modules when errors are
found.
Even the YANG repos simply maintain the uncorrected versions.


/js
>
>
Andy


> --
> Jürgen Schönwälder              Jacobs University Bremen gGmbH
> Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
> Fax:   +49 421 200 3103         <https://www.jacobs-university.de/>
>
> _______________________________________________
> netmod mailing list
> netmod@ietf.org
> https://www.ietf.org/mailman/listinfo/netmod
>