Re: [netmod] YANG Versioning: filename recommendations for YANG Semver

Andy Bierman <andy@yumaworks.com> Tue, 02 April 2024 17:52 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 1726FC14F6AD for <netmod@ietfa.amsl.com>; Tue, 2 Apr 2024 10:52:37 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.095
X-Spam-Level:
X-Spam-Status: No, score=-2.095 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=yumaworks.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id yOoaegV6xiFU for <netmod@ietfa.amsl.com>; Tue, 2 Apr 2024 10:52:31 -0700 (PDT)
Received: from mail-pj1-x1032.google.com (mail-pj1-x1032.google.com [IPv6:2607:f8b0:4864:20::1032]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id CEF29C14F5FB for <netmod@ietf.org>; Tue, 2 Apr 2024 10:52:31 -0700 (PDT)
Received: by mail-pj1-x1032.google.com with SMTP id 98e67ed59e1d1-29c14800a7fso3641101a91.2 for <netmod@ietf.org>; Tue, 02 Apr 2024 10:52:31 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yumaworks.com; s=google; t=1712080351; x=1712685151; darn=ietf.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=2Tg/KXi2ashSBh/VOzuV/MiZZcgw1ThNfcvw3ja2wPE=; b=cUcQFJK9SatKdzTB27+BIThgrlBA7rVkAAczZafUR4yW27FF9GLqASrUTX9OMLDbEs Vk9IVgx8hX8HE8DNcDQt5VJ2Dygi8+lQrOj4+7YBekcao+BurSlEnYcCodHZ7OX+Z0uk e4Rrw8fr8ZtQ2s7oSQc4lkEnv5EBvrSf+Xy3GgHhP4Xi+U05hYLOl2jbchtysYTzuWBt YRNMZBR9SwmfyZeqknRazN98jD/6J/Xj4JM36OES0uZRuGt3M5SfPRsLxbRW9v4p7l61 //Y5/ZeuwR7BXu0h/XDWZ6nYxsLXF757wN7sOxIyEjFtDMCOeCxTDn9fGhJVK9g/xwae 0l8Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712080351; x=1712685151; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=2Tg/KXi2ashSBh/VOzuV/MiZZcgw1ThNfcvw3ja2wPE=; b=LCCDsnhMMWUIdxXSw9cZTWCPmEGBcb/vOlJgv64ks+XB6eS9/yDh3QVA6QPz6Bx9Z8 T7UwLq2M5hSRtvIxJprzpjYP8vFhpPMDZWDgfvlCwWTVpUdgaUc3vokh6EqXRakUy0H7 FBft//TaOEmhtvEiflM2fivHH3wS9YaCDqhOCvX/9SvwC4ZzQvc/4hk3m8YrFW5DD6xS FWjTGoOJYfkxw7B3wtGrsYpEah6Zi6Ya3EnlTxxA8v9/IYJUmP+VDGAGnRJgYvmFPasf wEpFs0K87V9YnmmSCsJntFTvOn8JyLFE5ZRWcQqfdecdXi+zfz1hMgzwvV9KXfKgRsk+ 2nZg==
X-Gm-Message-State: AOJu0Yw8IHMmAzEcvu5YC63172pR8HTjF7X20gwitS0qJbx1tazIEVeB hyuWWQndtzSwf8wSNMysaSBq4/hbfAjdGS5Bs9IAFDfiOCXUsJNbwLXE9B4QT0+ryJNU+6m71H1 vJuDeow2/td7xoP9sqESJQPgE0GtqN3rCYIb3ZLpCE27hMIdefag=
X-Google-Smtp-Source: AGHT+IGb+aI+X11K5zIa0MLzEimG9CbUuPG5XNvzXJJ8FZdehJeoLYn0fugHdY3DG+kcjxSkZVdYZU4kZtjHLjqBajk=
X-Received: by 2002:a17:90a:420a:b0:2a2:3223:1930 with SMTP id o10-20020a17090a420a00b002a232231930mr6923640pjg.8.1712080350913; Tue, 02 Apr 2024 10:52:30 -0700 (PDT)
MIME-Version: 1.0
References: <SN6PR08MB484796C238E42AD91D29FA5F9B3E2@SN6PR08MB4847.namprd08.prod.outlook.com>
In-Reply-To: <SN6PR08MB484796C238E42AD91D29FA5F9B3E2@SN6PR08MB4847.namprd08.prod.outlook.com>
From: Andy Bierman <andy@yumaworks.com>
Date: Tue, 02 Apr 2024 10:52:19 -0700
Message-ID: <CABCOCHQk6BovHW7FA_moB+xrs8B1TH8eKmyiC1bco8WregvqBg@mail.gmail.com>
To: "Jason Sterne (Nokia)" <jason.sterne=40nokia.com@dmarc.ietf.org>
Cc: "netmod@ietf.org" <netmod@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000024c10a061520c56a"
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/z3CnxJbWJjtVCH39G_k07xdP6DA>
Subject: Re: [netmod] YANG Versioning: filename recommendations for YANG Semver
X-BeenThere: netmod@ietf.org
X-Mailman-Version: 2.1.39
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: Tue, 02 Apr 2024 17:52:37 -0000

Hi,

I do not agree with these recommendations to change the file names of YANG
modules.
The OFFICIAL YANG version is RFC 7950 - YANG 1.1.
Any module using YANG version 1.1 needs to follow the rules in RFC 7950.
Additional file naming that can be ignored by YANG 1.1 tools is OK.

I do not understand how a 1:1 deterministic mapping is achieved, based on
the YANG SemVer spec:

https://www.ietf.org/archive/id/draft-ietf-netmod-yang-semver-15.html#name-yang-semver-pattern

       1.0.3
       1.0.3_compatible
       1.0.3_non_compatible

The SemVer draft is confusing.

      YANG artifacts that employ semantic versioning as defined in this
document MUST use a version identifier
      that corresponds to the following pattern: 'X.Y.Z_COMPAT'.

And also:

      Additionally, [SemVer] defines two specific types of metadata that
may be appended to a semantic version string.  ....

Examples from sec 6:

      1.0.0-alpha.1

      1.0.0-alpha.3

      2.1.0-beta.42

      3.0.0-202007.rc.1


How do these strings conform to the pattern specified in sec. 4.3?

How is the revision label in the filename useful if the same string
actually identifies multiple revisions?


Andy



>
> At IETF 119, during the YANG Versioning discussions, there was a
> suggestion to raise the filename issue again as one last issue to resolve
> before going to last call.
>
>
>
> Version 10 of Module Versioning had the following content that was
> subsequently removed in version 11:
>
>
> https://datatracker.ietf.org/doc/html/draft-ietf-netmod-yang-module-versioning-10#name-file-names
>
>
>
> 3.4.1.  File names
>
>
>
>    This section updates [RFC7950] section 5.2, [RFC6020] section 5.2 and
>
>    [RFC8407] section 3.2
>
>
>
>    If a revision has an associated revision label, then it is
>
>    RECOMMENDED that the name of the file for that revision be of the
>
>    form:
>
>
>
>      module-or-submodule-name ['#' revision-label] ( '.yang' / '.yin' )
>
>
>
>        E.g., acme-router-module#2.0.3.yang
>
>
>
>    YANG module (or submodule) files may be identified using either the
>
>    revision-date (as per [RFC8407] section 3.2) or the revision label.
>
>
>
> At least one major implementation is already using YANG Semver in
> filenames, and the IETF 119 attendees raised the concern that if we don’t
> specify a desired filename format, then an de-facto standard will likely
> occur. Or perhaps we’ll end up with multiple competing approaches to having
> a YANG Semver in a filename.
>
>
>
> There are a number of advantages of having the key version identifier in
> the filename (hence why it is recommended in RFC 7950 and RFC 8407).
> Resolving the new ‘recommended-min’ extensions in Module Versioning and
> YANG Semver would also be easier if the YANG Semver is right in the
> filename.
>
>
>
> In the IETF 118 Hackathon, Per demonstrated that modifying pyang to handle
> the additional filename format was a fairly trivial change. But it still
> may take other tool authors time to update other tools.
>
>
>
> Some potential issues for us to consider & discuss as a WG:
>
>    1. Should we mention anything about potential use of symlinks (e.g.
>    instead of having 2 copies of a module with two different filenames, one
>    with revision date, the other with YANG Semver, just have one of them
>    symlink to the other?)
>    2. The YANG Semver draft mandates that IETF YANG modules have a YANG
>    Semver. Do we also need to recommend/mandate something specific about
>    filenames for IETF YANG modules (e.g. in the CODE BEGINS line in RFCs)?
>    3. Will most tools that haven’t been modified yet to recognize the new
>    filename format simply interpret the #X.Y.Z as part of the module name?
>    Will they complain that the filename doesn’t match the module name?
>    4. Will some tools & processes fail because of the “#” (i.e. consider
>    it a comment marker and chop off the chars that follow)?
>
>
>
> Another possible approach is something along these lines:
>
> **If** you are going to put a YANG Semver into a module filename, then
> you MUST use this format:   <name>#<yang semver>.yang
>
>
>
> That doesn’t preclude having both a revision date format and a YANG Semver
> format, but doesn’t specifically suggest to use one or the other. Then
> perhaps YANG-NEXT could mandate the YANG Semver filename format?
>
>
>
> So the big questions are:
>
>    - Whether to include this filename convention in the YANG Semver draft?
>    - How strong a recommendation/mandate should it be?
>
>
>
> Jason (he/him)
>
>
> _______________________________________________
> netmod mailing list
> netmod@ietf.org
> https://www.ietf.org/mailman/listinfo/netmod
>