Re: [netmod] Instance-data-format - shall we define etag and last-modified annotation ?

Andy Bierman <andy@yumaworks.com> Tue, 23 July 2019 15:39 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 5F882120398 for <netmod@ietfa.amsl.com>; Tue, 23 Jul 2019 08:39:11 -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, RCVD_IN_DNSWL_NONE=-0.0001, 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=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 k3JP1HHjwAkI for <netmod@ietfa.amsl.com>; Tue, 23 Jul 2019 08:39:08 -0700 (PDT)
Received: from mail-lj1-x22f.google.com (mail-lj1-x22f.google.com [IPv6:2a00:1450:4864:20::22f]) (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 A9E7F120428 for <netmod@ietf.org>; Tue, 23 Jul 2019 08:39:07 -0700 (PDT)
Received: by mail-lj1-x22f.google.com with SMTP id m8so7907752lji.7 for <netmod@ietf.org>; Tue, 23 Jul 2019 08:39:07 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yumaworks-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=vkKvwRCZYm3kNAvNIi+NfjkDOvo5KrkLpOes5Y5xi/k=; b=bgqg2Nk7wXiYi3itKxXxVqkDPADnr67ggiz7QoPWzOacw3ERsfCVOq3h3sHMWbxX1d W6bEVkb4NZ/LpZ68KyW/y2p2cY9WJtDXbYtWCvsZdeP8AcicEZn5NhNT7PD6IDhH6PRK CRsIt18Q48yGLOq+shRiIATCwJqSDjwqlcI/ho5jXqIDmvALnuKr2fu5F2QL2vYrxFhO MIuffxoSIHU2hz661rvKQIrlQq4dqHOZ/qaP//hAcw0xvc2vivrq4aA5ZqtWYZDzjwFF Rckj6/fsi4HRG5Hyp6oL0of/8fe0w2FoO1o9evgKMd40P8mzhM14pLcc+P/2N6NuKcrf SuCA==
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; bh=vkKvwRCZYm3kNAvNIi+NfjkDOvo5KrkLpOes5Y5xi/k=; b=t0oTIOvzqIyhHu+qH8MveKkzUsrbekbMHsrLM77zjtl5+ZiHR9isVlRrXoNCheuwPe VbKBjKBszZpq0fta58HoyklFAfCYOAPdUx5fxtUUVQ25mzT+VpC+r4xHHwBGrPFz3fB4 jXK4cqnJ8MIa/zrdLvZdwsfNcRNc/IGfg3zafhXVi3PRJdaYLu2EJjtx1Rc6i1QmiT2T F2ZhnO5hhfEqOSF3BqEIKxbixXmbNlo8+nt8U3xyLUSp136hF2VJsErYEc/tUNhJbgBC ZwXlfCvU699VV3rdsgQnsoTxulQm0hlbIqEBZNLuvAlCX22jQmNbNLEjE4i/FsHkD5Ve v+1w==
X-Gm-Message-State: APjAAAV0lh+OCUmff1Ip2SBiAw2vjnPqebxnNSPnpz2ALZAEbSHBTsFq 90+SBr4mfBktWFNGAHC8J89M8MMhh//HCQ4R1VY0gQ==
X-Google-Smtp-Source: APXvYqycHa5qMcfv+BWJBvOIJfGUCBjUG5cEadcnRefOnwC6s7SlfrKOhSHieVwg7Xo9kMN1iEDM3tyCDAiF/KlOI44=
X-Received: by 2002:a05:651c:1b9:: with SMTP id c25mr11318854ljn.25.1563896345770; Tue, 23 Jul 2019 08:39:05 -0700 (PDT)
MIME-Version: 1.0
References: <VI1PR0701MB2286D806027F541651B0BCE6F0C40@VI1PR0701MB2286.eurprd07.prod.outlook.com> <20190722201510.mom7xg2mdi2ulbby@anna.jacobs.jacobs-university.de> <VI1PR0701MB2286001A8E05E099C066BF61F0C70@VI1PR0701MB2286.eurprd07.prod.outlook.com> <20190723142414.4sc5o2j6dawblwrm@anna.jacobs.jacobs-university.de>
In-Reply-To: <20190723142414.4sc5o2j6dawblwrm@anna.jacobs.jacobs-university.de>
From: Andy Bierman <andy@yumaworks.com>
Date: Tue, 23 Jul 2019 08:38:54 -0700
Message-ID: <CABCOCHQrAQaK2XEfnC9EPwhsu4+Qe=tPyLe-bT9=7x9t1LN3BQ@mail.gmail.com>
To: Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>, =?UTF-8?Q?Bal=C3=A1zs_Lengyel?= <balazs.lengyel@ericsson.com>, "netmod@ietf.org" <netmod@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000027d0ec058e5afe50"
Archived-At: <https://mailarchive.ietf.org/arch/msg/netmod/Pml-VmGyjgAqhXfQwF7pLSRAtjQ>
Subject: Re: [netmod] Instance-data-format - shall we define etag and last-modified annotation ?
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: Tue, 23 Jul 2019 15:39:22 -0000

On Tue, Jul 23, 2019 at 7:24 AM Juergen Schoenwaelder <
j.schoenwaelder@jacobs-university.de>; wrote:

> Balázs,
>
> I am not sure these belongs to the data types collection. If these
> annotations are a per datastore properties or per configuration
> datastore properties (I am not sure these properties make a lot of
> sense for dynamically changing data in <operational>, or these
> properties only make sense for config true nodes, more discussion
> needed I guess), then the logical place would be to define them would
> be where the datastores are defined.
>
> I understand the timing concern but my preference is to workout what
> these annotations really are in an NMDA world and in a second step to
> figure out a way to define them in a reasonable amount of time.
>
>
This work needs a lot more thought because this WG is sort of abusing these
fields,
intended for HTTP caching. The values are associated with a representation
of a response
to a request for some portion of the datastore contents.  E.g., a
representation in XML must be a different
ETag than a JSON representation (of the exact same datastore contents).

I suggest new meta-data be defined that has semantics specific to datastore
contents, not
the HTTP representation of the response.

IMO this meta-data is not really needed inside an instance file, but if
included, then the values
should be associated with the representation (the instance file) and not
the datastores.


/js
>


Andy


>
> On Tue, Jul 23, 2019 at 02:11:23PM +0000, Balázs Lengyel wrote:
> > Hello Jürgen,
> > Could the etag and last-modified annotations be moved to 6991bis?
> > Regards Balazs
> >
> > -----Original Message-----
> > From: Juergen Schoenwaelder <j.schoenwaelder@jacobs-university.de>;
> > Sent: 2019. július 22., hétfő 16:15
> > To: Balázs Lengyel <balazs.lengyel@ericsson.com>;
> > Cc: netmod@ietf.org
> > Subject: Re: [netmod] Instance-data-format - shall we define etag and
> > last-modified annotation ?
> >
> > On Mon, Jul 22, 2019 at 07:23:59PM +0000, Balázs Lengyel wrote:
> > > Hello,
> > >
> > > Restconf (rfc8040) defined to useful bits of metadata about a YANG
> > > defined
> > > datastore: entity-tag and the last-modified timestamp.
> > >
> > > These can be very useful in instance data sets, however Restconf
> > > defines an encoding for these (as part of the http headers) that can
> > > not be used in instance-data-sets.
> >
> > This may actually point out a flaw or omission of RFC 8527. RFC 8040
> defines
> > an entity-tag for its "unified" datastore and it says "if the RESTCONF
> > server is co-located with a NETCONF server, then this entity-tag MUST be
> for
> > the "running" datastore". So it is a bit unclear what happens with other
> > NMDA datastores and I did not quickly find something in RFC 8527. (For
> > example, can have a distinct etag for <startup/>?
> >
> > > draft-ietf-netmod-yang-instance-file-format-03#section-7.2
> > >
> > <
> https://tools.ietf.org/html/draft-ietf-netmod-yang-instance-file-format-03#
> > > section-7.2>     defines metadata annotations for these two, that can
> be
> > > used in instance data
> > >
> > >   md:annotation entity-tag {
> > >       type string;
> > >       description "Used to encode the entity-tag .";
> > >     }
> > >     md:annotation last-modified {
> > >       type yang:date-and-time;
> > >       description "Contains the date and time when the annotated
> > >         instance was last modified (or created).";
> > >     }
> > >
> > > In order to be able to include this data, the annotations need to be
> > > defined in some YANG module.
> > >
> > > The question has been raised whether
> > >
> > > 1.  these annotations should be defined in the ietf-yang-instance-data
> > > module as it needs them, as that is open or
> > > 2.  the annotations should be defined in another draft in a separate
> > > YANG module as any other annotation
> > >
> > > The first option is better because the instance-data needs these
> > > annotations, and at this point we see no other user for the
> > > annotation, and in this case the ongoing instance data draft will
> > > define it
> > >
> > > The second option is better because, if later there are other users
> > > for these annotations, it might be strange to reference the
> > > ietf-yang-instance-data module. Also why provide special treatment to
> > > these
> > > 2 annotations?
> > >
> > > The authors support option 1 and don't have the time to start a new
> > > draft to define these annotations.
> > >
> > > On IETF105 in the room there was more support for option 1.
> > >
> > > Please indicate if you have an opinion about the choice of 1 or 2
> >
> > Version -03 only defines these annotations but does not do anything
> specific
> > with these definitions. So if the annotations are defined elsewhere, the
> ID
> > is as complete as before. If entity-tag and last-modified are actually
> seen
> > as datastore properties, it would be nice to have them defined in the
> NMDA
> > documents (and it seems we overlooked this when we did the NMDA work).
> >
> > I think this needs a bit of discussion whether these are actually seen as
> > datastore properties. But in this case, I would lean towards option 2.
> >
> > /js
> >
> > --
> > Juergen Schoenwaelder           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/>
>
>
>
> --
> Juergen Schoenwaelder           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
>