Re: [netmod] Module tags

Andy Bierman <andy@yumaworks.com> Fri, 10 February 2017 21:36 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 162F8129461 for <netmod@ietfa.amsl.com>; Fri, 10 Feb 2017 13:36:25 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.6
X-Spam-Level:
X-Spam-Status: No, score=-2.6 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_LOW=-0.7, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=yumaworks-com.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 hJnv3DR9icPN for <netmod@ietfa.amsl.com>; Fri, 10 Feb 2017 13:36:22 -0800 (PST)
Received: from mail-wm0-x22e.google.com (mail-wm0-x22e.google.com [IPv6:2a00:1450:400c:c09::22e]) (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 74A01129436 for <netmod@ietf.org>; Fri, 10 Feb 2017 13:36:22 -0800 (PST)
Received: by mail-wm0-x22e.google.com with SMTP id v77so59232899wmv.0 for <netmod@ietf.org>; Fri, 10 Feb 2017 13:36:22 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yumaworks-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=iVMQyKNkM4sN9LJpMsP+eZ/okfcYUDHv9QH+Dil5vuM=; b=hsuqAKUiOiLraPUrSDKr/M2HQZ2ZoWT58wHiNgMfneoko8fHdNTlEv+b4GEFhepNl5 nWvu49fTKyJG7jpWABPvR25iXLrTyVPT98bukklmgAIGjbZSdGlrJawttFDQIQCdmHUM GN50kOJ8nPw5VWV7PIU/jSWdR22RPHMywI7x8YGTP/GgfKUPJYbN7Caui05xLq6XoYbb nBXOHgbUKgaPDROk6WzxYXdb7EAGw6zsDuU8qY374W3L67pJwbjAQFRvYJQ6c1KfW7tY DPWoSSDLAsnU3KY0+EtWe1vx54Eg5hpL2hcmK3riQDsC1OnUptJoKirX1EFhv+tyPMRk 9Y1g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=iVMQyKNkM4sN9LJpMsP+eZ/okfcYUDHv9QH+Dil5vuM=; b=MGm3xsI3U5RamW6s6haSl8wRqlVUN3FYhUW5jHGASVimys0l//6V5sqzDa3lq8/3JP OCIqlMweItIFWldkPqFiX2fndNNsfs/WnGNniVfa/syGvUibuQUFRHrPRF1S4N2tyEEP gXLt1CJkbZ2cOqt8cUY7swEKkFJMVSXvMpmlvNHZfUkLOuDwPiihS00FKl1nbq1clBAh mOJ1cWWGwTGM66Kakn6velDWYkG6soHmxEocnFh06Ir9vHXek08McXaomh/04kYBXPzH 5EmjPBQfgbjTW8QnsO7XJ8ycz0q+SIXZebLjgtzJLEsRYcZ0tRNsYcK7nXuOEJjqI3BP L45w==
X-Gm-Message-State: AMke39mb+6EaOZlnEshM3nFkpbfStMSRa1XihtSRvUXue72djbitXsn7wcrnBn/A3f9a+T8jFYlZ60q+VoCOlw==
X-Received: by 10.28.103.3 with SMTP id b3mr26703326wmc.99.1486762580883; Fri, 10 Feb 2017 13:36:20 -0800 (PST)
MIME-Version: 1.0
Received: by 10.223.131.67 with HTTP; Fri, 10 Feb 2017 13:36:20 -0800 (PST)
In-Reply-To: <20170208.231709.2214078600549867460.mbj@tail-f.com>
References: <87shnogymx.fsf@chopps.org> <20170208.231709.2214078600549867460.mbj@tail-f.com>
From: Andy Bierman <andy@yumaworks.com>
Date: Fri, 10 Feb 2017 13:36:20 -0800
Message-ID: <CABCOCHQJ+ef4C=TAfH9NK47mWgO0XOy1gg-cggigWq7Fqdfkgw@mail.gmail.com>
To: Martin Bjorklund <mbj@tail-f.com>
Content-Type: multipart/alternative; boundary="001a114a91b27fd6dc054833e3fa"
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/-yVh-j-L3iyZNup9g8Fre4rJIF8>
Cc: "netmod@ietf.org" <netmod@ietf.org>
Subject: Re: [netmod] Module tags
X-BeenThere: netmod@ietf.org
X-Mailman-Version: 2.1.17
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: Fri, 10 Feb 2017 21:36:25 -0000

On Wed, Feb 8, 2017 at 2:17 PM, Martin Bjorklund <mbj@tail-f.com> wrote:

> Christian Hopps <chopps@chopps.org> wrote:
> >
> > Martin Bjorklund <mbj@tail-f.com> writes:
> > > Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de> wrote:
> > >> On Wed, Feb 08, 2017 at 01:22:01PM -0500, Christian Hopps wrote:
> > >> >
> > >> > The tags in the library and the tags in a module are updated at the
> same
> > >> > time and represent logically the same list of tags. Its clear this
> > >> > happens with an RPC. It seems a lot less clear this would (or
> should)
> > >> > happen if one edited only once location.
> > >>
> > >> I am not convinced by the design. We have lots of other resources
> > >> where we have configured and system determined values. I do not see
> > >> that tags are any different.
> > >
> > > I agree.  *If* you want a config true datastructure, it should be
> > > modified with the normal edit operations, not special RPCs.  There are
> > > several reasons for this.  For example, how would your new RPCs
> interact
> > > with locks?  With candidate?  With startup?
> >
> > The point of already existing mechanisms and locks is somewhat
> > compelling. Although this data is not very dynamic so it's hard to
> > imagine locks coming into play, but the point is still taken.
> >
> > So if the user changes the tags on a module using the module path can we
> > just indicate that it would automatically also update in the yang
> > library list?
>
> Sure.
>
> > We use a grouping that gets stamped inside a module and
> > then we have another module define the yang library notation would we
> > simply define the semantics in text and outside of yang?
>
> In the description should work.
>
> > It's easy for
> > the module grouping to refer to the yang library but the reverse is not
> > true.
> >
> > > Also I am not sure it is a good idea to add configuration meta-data
> > > that really should be common across all modules into the modules
> > > themselves.  Another approach is to keep a separate list with the
> > > tags, indexed by modulename and revision.
> >
> > I don't understand what your getting at here. Are you referring to the
> > grouping that gets used by a module author inside their module? The tags
> > set for a given module are specific to that module only.
>
> I meant that instead of using the grouping in every module, you could
> have a separate structure in your module:
>
>   container module-tags {
>     list module {
>       key "name revision";
>       leaf name { ... }
>       leaf revisoin { ...}
>       leaf-list tag { ... }
>     }
>   }
>
> This way you will handle configuration of tags for all modules, and
> they don't have to have a special uses statement.
>
>
+1.

I read the draft, and I agree with you that the single container solution
is best. Looks like configuration data to me, and no need for any special
case editing models.

Oddly, the draft relies on XPath filtering to retrieve modules with a
certain tag.
There is no <find-tags> operation.
That is the 1 RPC operation that might be justified.

e.g.:

  rpc find-tags {
    description "find all modules with the specified tag(s).";
     input {
       leaf-list tag { type string; }
     }
     output {
       leaf-list module-name { type string; }
     }
   }


> /martin
>
>
>
>
Andy


> _______________________________________________
> netmod mailing list
> netmod@ietf.org
> https://www.ietf.org/mailman/listinfo/netmod
>