[netconf] Re: Default statements on udp-client-server groupings

Kent Watsen <kent+ietf@watsen.net> Tue, 10 September 2024 19:18 UTC

Return-Path: <01000191dd5fee26-d7465934-4131-40b1-9549-ff693917b0d6-000000@amazonses.watsen.net>
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 33B94C15109A; Tue, 10 Sep 2024 12:18:59 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.906
X-Spam-Level:
X-Spam-Status: No, score=-6.906 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, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=amazonses.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 VIKClsS9k6rN; Tue, 10 Sep 2024 12:18:58 -0700 (PDT)
Received: from a48-94.smtp-out.amazonses.com (a48-94.smtp-out.amazonses.com [54.240.48.94]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 77FD5C151083; Tue, 10 Sep 2024 12:18:58 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=ug7nbtf4gccmlpwj322ax3p6ow6yfsug; d=amazonses.com; t=1725995937; h=From:Message-Id:Content-Type:Mime-Version:Subject:Date:In-Reply-To:Cc:To:References:Feedback-ID; bh=YGWiCPdi7tdDEw1stjpUd9TeULIANz4nFASyZ4NKZnE=; b=MxqiVEcS8pf9Lj/CPW8+v4k19qL6THXn/1wqTI17LZ7HZmnIwxI7hD14ZWHcI8JK IM8jrArSR7Rk01Z9+iOHa6K0ajlodCnlrdBqZFqvBsI5njWe6Hl9P37FjJdsYE6va49 h5DBDHJBRENZTtzjTjVHNh5EwYkBfCdyBnmpfaok=
From: Kent Watsen <kent+ietf@watsen.net>
Message-ID: <01000191dd5fee26-d7465934-4131-40b1-9549-ff693917b0d6-000000@email.amazonses.com>
Content-Type: multipart/alternative; boundary="Apple-Mail=_EEA0E061-EEA3-43C2-B101-91249E3C57AD"
Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.400.31\))
Date: Tue, 10 Sep 2024 19:18:57 +0000
In-Reply-To: <CABCOCHT6Wsh=mwpPNq+3nGzf8EU8fGtwvstakEtbPetTsL9NDQ@mail.gmail.com>
To: Andy Bierman <andy@yumaworks.com>
References: <EAA84133-F9D5-4380-994D-297993F13675@insa-lyon.fr> <01000191dc9a8080-119f64d0-f1d7-4549-9789-ba05daa87609-000000@email.amazonses.com> <CABCOCHRYQmo+XDZMGuTwNJ+OW2F1ZbRDcjMst40Z0GXpFD86-w@mail.gmail.com> <01000191dcc4509d-0c99ab29-a02e-4a3e-b68b-3b1d58a87f27-000000@email.amazonses.com> <CABCOCHT6Wsh=mwpPNq+3nGzf8EU8fGtwvstakEtbPetTsL9NDQ@mail.gmail.com>
X-Mailer: Apple Mail (2.3774.400.31)
Feedback-ID: ::1.us-east-1.DKmIRZFhhsBhtmFMNikgwZUWVrODEw9qVcPhqJEI2DA=:AmazonSES
X-SES-Outgoing: 2024.09.10-54.240.48.94
Message-ID-Hash: 5IH4MXHYMNWB3JPTT7T7Q7NVQI2FMT4B
X-Message-ID-Hash: 5IH4MXHYMNWB3JPTT7T7Q7NVQI2FMT4B
X-MailFrom: 01000191dd5fee26-d7465934-4131-40b1-9549-ff693917b0d6-000000@amazonses.watsen.net
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-netconf.ietf.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: "netconf@ietf.org" <netconf@ietf.org>, draft-ietf-netconf-udp-client-server.authors@ietf.org
X-Mailman-Version: 3.3.9rc4
Precedence: list
Subject: [netconf] Re: Default statements on udp-client-server groupings
List-Id: NETCONF WG list <netconf.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/netconf/mIjNZH4x9qa6XTQTdwycvjR9-Lk>
List-Archive: <https://mailarchive.ietf.org/arch/browse/netconf>
List-Help: <mailto:netconf-request@ietf.org?subject=help>
List-Owner: <mailto:netconf-owner@ietf.org>
List-Post: <mailto:netconf@ietf.org>
List-Subscribe: <mailto:netconf-join@ietf.org>
List-Unsubscribe: <mailto:netconf-leave@ietf.org>

Hi Andy,

>> And here is in the “tcp-client-grouping” grouping:
>> 
>>      leaf remote-port {
>>        type inet:port-number;
>>        default "0”;                          <--  THIS IS THE LINE BEING CONTESTED 
>>        description                                    ^— it seems 50/50 if useful, but it doesn’t harm either, does it?
>>          "The IP port number for the remote peer to establish a
>>           connection with.  An invalid default value is used
>>           so that importing modules may 'refine' it with the
>>           appropriate default port number value.";
>>      }
>>      leaf local-port {
>>        if-feature "local-binding-supported";
>>        type inet:port-number;
>>        default "0";                          <—  AND THIS LINE ALSO
>>        description                                    ^— this seems like a *good* value for all services, e.g., universal behavior
>>          "The local IP port number to bind to for when connecting
>>           to the remote peer.  The port number '0', which is the
>>           default value, indicates that any available local port
>>           number may be used.";
>>      }
>> 
>> 
> 
> 
> default "0" should be removed.

Which one?  I assume just the one in “remote-port”, since the one in “local-port” is used.


> Using zero as a special value to mean "not set"  is a common hack, but not good practice in YANG.

Okay, I agree.  It’s better for remote-port to not specify a default "0”.

NEW:

     leaf remote-port {
       type inet:port-number;
       description
         "The IP port number for the remote peer to establish a
          connection with.  Importing modules should 'refine' in
          an appropriate default port number value.";
     }

Good?

PS: I just made this change to my local copy of the tcp-client-server document, and then recompiled to entire suite of client-server documents without error, meaning all examples are still valid.  This is great because it can be a very focused request to RFC Editor.

K.


> Andy