Re: [netconf] WG adoption poll for draft-wwlh-netconf-list-pagination-rc

Andy Bierman <andy@yumaworks.com> Thu, 24 March 2022 01:56 UTC

Return-Path: <andy@yumaworks.com>
X-Original-To: netconf@ietfa.amsl.com
Delivered-To: netconf@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id BE7FE3A02D0 for <netconf@ietfa.amsl.com>; Wed, 23 Mar 2022 18:56:07 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.897
X-Spam-Level:
X-Spam-Status: No, score=-1.897 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, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_PERMERROR=0.01, 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.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 O8n21A8Cyl6N for <netconf@ietfa.amsl.com>; Wed, 23 Mar 2022 18:56:02 -0700 (PDT)
Received: from mail-yb1-xb2b.google.com (mail-yb1-xb2b.google.com [IPv6:2607:f8b0:4864:20::b2b]) (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 577CD3A00D3 for <netconf@ietf.org>; Wed, 23 Mar 2022 18:56:02 -0700 (PDT)
Received: by mail-yb1-xb2b.google.com with SMTP id z8so5984156ybh.7 for <netconf@ietf.org>; Wed, 23 Mar 2022 18:56:02 -0700 (PDT)
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 :cc; bh=ZQkJDLIIUX0Yjhv3RQkB6BpYR3MwOYwkIgGJI/N/pbY=; b=frt2d49DCa4c3SLwRyqXlbbb4SJoyRb7/O0HGJnUgmbp7fQpwyxjg4jGk72Wmh6y0R bGElEwAKsIfmUUHxLaZTCma41whtXm0wm15Ag4U0xkrLInrYpPF1ujD5/XcVQBhHD6qQ 5MIFrnY2zD045+Ls9lWLvHHHzX7MdxyG4AUjVXwhD1zSkpoctAKJtlJ1SEjdKYCyj/BF ulHf9HA8d8EZxklroRQPXfdhBM3LJcIhX5xlzPqYS40+9fa3R0YuCluGIBGCTBii3kTL IgDQOqDHT05vOV24ufSjElJ7Jiq1WNJ9QzK6+uwVOtCMD8ivISl+YmunIBA/8VUC1UaP PqVA==
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:cc; bh=ZQkJDLIIUX0Yjhv3RQkB6BpYR3MwOYwkIgGJI/N/pbY=; b=oW5zTcgXY+jmHpBDZBdVtzc1b+rlu6CVs+VhGlvxAR08UAjKKgp/SqJZMrvY2m1JFE lquP+SGz0rhQHnAzIJHoqAKZ319s/tzEqGh0kgGz29gKFL7kySB1a2KdQoTqbHL85LLR 6t4NEpWkX9NR3EWp40l/mAevYTpqJx9dTNWrEmnXYH7hjJmKJ4aqW5Nkcz+VW2sNee+M oELjXHS906v5349YgsRn1otlm9hModOcXGgmGSOZAYNHaZYJIPKVbhHta9YIme5D2THW ccAbm/l+J0UQA6WjlLj4iJoXHQ5UCmzdW0CLLQNv4AOhipRjgkKZaV4dl718LjcxdrEI +5jQ==
X-Gm-Message-State: AOAM532NoZ9cC4YMQ4yBbF3i6drkfxdQuRJeRrpxKTDr4Hsf/H4kbM/m P1pTltoNB9ZsNHP3XOgFA6aXb35jUk5ipV9o2hafDS/O6+v7mg==
X-Google-Smtp-Source: ABdhPJxCotzsNA6sMklgRtwNbCJNAjfr7o8RpZ8Z+B26FD63f5kYTSr49PDq+mDQylTqI20ClemdqTKPf1KM/oAWBpQ=
X-Received: by 2002:a5b:842:0:b0:633:75b6:4129 with SMTP id v2-20020a5b0842000000b0063375b64129mr2835670ybq.64.1648086960890; Wed, 23 Mar 2022 18:56:00 -0700 (PDT)
MIME-Version: 1.0
References: <CE977237-19F4-4C16-B45E-E4ED75706158@gmail.com> <e930f61906f6433fadc4bfc909a6e4e3@huawei.com> <CABCOCHT4TqxsowyJgE39wtELdN3X52t_m=J3cJMN+g4ASjai5A@mail.gmail.com> <0100017fb87b4470-e130bf0b-fc62-4eb4-8e6d-6032eb345564-000000@email.amazonses.com>
In-Reply-To: <0100017fb87b4470-e130bf0b-fc62-4eb4-8e6d-6032eb345564-000000@email.amazonses.com>
From: Andy Bierman <andy@yumaworks.com>
Date: Wed, 23 Mar 2022 18:55:50 -0700
Message-ID: <CABCOCHS8uLcb8DA2q_1shWf9S-J1-aUexjhje_-Fbosrv2p45w@mail.gmail.com>
To: Kent Watsen <kent@watsen.net>
Cc: "maqiufang (A)" <maqiufang1=40huawei.com@dmarc.ietf.org>, "netconf@ietf.org" <netconf@ietf.org>
Content-Type: multipart/alternative; boundary="000000000000dcf93705daed2537"
Archived-At: <https://mailarchive.ietf.org/arch/msg/netconf/gi3OP0N1dq6TSw4qHNvo91ZfYCw>
Subject: Re: [netconf] WG adoption poll for draft-wwlh-netconf-list-pagination-rc
X-BeenThere: netconf@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: NETCONF WG list <netconf.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netconf>, <mailto:netconf-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/netconf/>
List-Post: <mailto:netconf@ietf.org>
List-Help: <mailto:netconf-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/netconf>, <mailto:netconf-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 24 Mar 2022 01:56:08 -0000

On Wed, Mar 23, 2022 at 1:32 PM Kent Watsen <kent@watsen.net> wrote:

> Hi Andy and Qiufang,
>
>
> On Mar 23, 2022, at 1:53 PM, Andy Bierman <andy@yumaworks.com> wrote:
>
> On Wed, Mar 23, 2022 at 4:18 AM maqiufang (A) <maqiufang1=
> 40huawei.com@dmarc.ietf.org> wrote:
>
>> Hi, Mahesh, all
>>
>> As a response to all three list-pagination drafts, I’ve read these three
>> drafts and support their adoption.
>>
>
> I have not examined the solution details closely enough.
> Not all details look like they have 1000s of hours of customer deployment
> usage
> like the basics implemented in real servers).  IMO standards like this one
> need
> to be based on proven technology (i.e. running code).
>
>
> Both the CLIXON and SZTPD products ship with half of this draft
> implemented, using two completely different DB-backends, and one author
> (Per) is from the Tail-f side of the Cisco-house and is ensuring
> compatibility there (it may be that Taif-f has a proprietary paging
> mechanism).   We welcome a Yumapro prototype to further ensure correctness.
>
>
https://www.yumaworks.com/pub/latest/netconfd/yumapro-netconfd-manual.html#get-bulk

We have a lightweight, stateless, bufferless solution called
'get-bulk' that is simply for iterating
through a YANG list, N entries at a time (with lots of filtering parameters
of course).
It does not rely on count or position, so additions and deletions "behind"
the current instance location do not affect the walk.

The pagination drafts provide stateful, resource-intensive advanced
features.
I don't have time right now to work on an implementation, but plan to
implement the RFC.

I really liked the original RESTCONF Collections proposal from Martin,
which required the client to create, use, and free a 'collection' resource.
It is much more efficient for both client and server if there is explicit
state
managed for this purpose.



> I do have one comment regarding list-pagination-rc draft:
>>
>> It makes sense to me that the draft extends RESTCONF protocol to add
>> “list” and “leaf-list” nodes as data resources and define a new media type
>> to encode list/leaf-list in XML.
>>
>> But when I understand that the draft also tries to extends RC DELETE
>> method to allow the deletion of a whole leaf/leaf-list, I have the
>> following feelings:
>>
>
>
>> 1)       It’s not in the scope of this list pagination work which
>> focuses more on list/leaf-list pagination retrieval( but I can understand
>> that the authors do this for completing RC solution);
>>
>
> +1
> There is no way that EDIT operations should be included in a pagination
> draft.
>
>
> These are reasonable objections.  The authors struggled mightily over the
> DELETE operation, but left it in so it could be a WG-discuss.  This will be
> treated as a post-adoption "open issue".
>
>
Just submit a new draft


>
>
> 2)   RFC8040 says “If the target resource represents a configuration leaf-list or list
>>
>>    data node, then it MUST represent a single YANG leaf-list or list
>>
>>    instance.  The server MUST NOT use the DELETE method to delete more
>>
>>    than one such instance.”(https://datatracker.ietf.org/doc/html/rfc8040#section-4.7)
>>
>> I am curious what’s the consideration for this design, is it because it’s a dangerous behavior?
>>
>> Because the authors of RFC 8040 were being silly...and I say that being
> one of them!  ;)
>

There were objections, based on lack of "REST Purity" in our solution
proposal.
The DELETE method can only apply to 1 resource.
BTW, we do not implement any delete-all for RESTCONF. (due to multiple
MUSTs in the RFC)




>
>
> yes -- how does the server know the difference between a client bug
> (forgot to include the keys)
> and an intentional "delete-all"?
>
>
> The server wouldn't know if the client has a bug, of course.  But, if
> discussing existing RC-clients, they currently cannot target a
> list/leaf-leaf (as a whole, not a specific entry) without the RC-server
> throwing an error.  Said existing RC-clients would have to be modified to
> introduce support to target a whole list/leaf-list.
>
>
There is text that says a list MUST have all keys present in the target
resource URL.
All leaf-lists MUST be specified with their value for DELETE.


>
> netconfd-pro has supported "delete-all" and "remove-all" values for
> the nc:operation attribute for many years.  It has to be enabled in the
> CLI,
> and then the client can explicitly specify the operation in a list or
> leaf-list target.
> It is widely used for leaf-list, and not so much for list.
>
> IMO the NETCONF and RESTCONF RFCs would need updates to support
> such an operation. Something for netconf-next and restconf-next wishlists.
>
>
> Are *-next updates technically necessary?   Clearly the intention is that
> the DELETE operation is only supported *if* the module is implemented by
> the server...so where is the harm?  If a client fails to test the server,
> the worst that happens is that it gets an RPC-error, right?
>


You are right. A server could advertise a YANG module, feature, capability,
etc
that indicates it allows a special edit mode.



> Separately, here we're just talking about RESTCONF, is it not possible to
> delete a whole list or leaf-list in NETCONF?
>
>
> Then why do we want to remove this restriction now?
>>
>>
> We don't.
> Not a priority and not in scope for this work.
>
>
> It's fair to say that a DELETE list/leaf-list operation is not-required,
> as list-pagination is fundamentally a read-only activity and, obviously,
> DELETE is not.
>
> That said, as soon as the new targets are defined, immediately folks will
> want to use the DELETE operation on them, don't you think?  This is
> something that comes up often; so much that current practice is to wrap
> lists and leaf-lists with container solely to enable whole-list deletion.
>


IMO list pagination is mostly useful for operational data
and bulk list deletion is not needed at all.

If this is needed for a specific config list, then it can be placed in its
own NP-container parent, so deleting the parent is the same as delete-all.


Andy



>
> Maybe I’ve missed something, but just curious.
>>
>>
>>
>> BTW, the “decimal64-numbers” parameter is defined as leaf-list in the list-pagination draft, rather than a “list”. But it’s mentioned as “list” in Appendix C.2 of list-pagination-rc(example of deletion of a list).
>>
>> Good catch!  Fixed in my local copy.
>
>
>
>>
>> Best Regards,
>>
>> Qiufang
>>
>>
> Andy
>
>
> Kent  // contributor
>
>
>