[Uri-review] Re: [art] Alternative representation of URIs in YANG
Tim Bray <tbray@textuality.com> Fri, 05 December 2025 05:19 UTC
Return-Path: <tbray@textuality.com>
X-Original-To: uri-review@mail2.ietf.org
Delivered-To: uri-review@mail2.ietf.org
Received: from localhost (localhost [127.0.0.1]) by mail2.ietf.org (Postfix) with ESMTP id 2689295CEF35 for <uri-review@mail2.ietf.org>; Thu, 4 Dec 2025 21:19:35 -0800 (PST)
X-Virus-Scanned: amavisd-new at ietf.org
X-Spam-Flag: NO
X-Spam-Score: -2.099
X-Spam-Level:
X-Spam-Status: No, score=-2.099 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_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: mail2.ietf.org (amavisd-new); dkim=pass (1024-bit key) header.d=textuality.com
Received: from mail2.ietf.org ([166.84.6.31]) by localhost (mail2.ietf.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GnjnwI9BNjnL for <uri-review@mail2.ietf.org>; Thu, 4 Dec 2025 21:19:34 -0800 (PST)
Received: from mail-pj1-x102a.google.com (mail-pj1-x102a.google.com [IPv6:2607:f8b0:4864:20::102a]) (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 mail2.ietf.org (Postfix) with ESMTPS id 50F1595CEF24 for <uri-review@ietf.org>; Thu, 4 Dec 2025 21:19:34 -0800 (PST)
Received: by mail-pj1-x102a.google.com with SMTP id 98e67ed59e1d1-343ff854297so1903860a91.1 for <uri-review@ietf.org>; Thu, 04 Dec 2025 21:19:34 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=textuality.com; s=google; t=1764911973; x=1765516773; 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=l1pQtBVtb8GselEP6sgwfIIPtuf2xz9Kb17eKElW0aE=; b=Dx3NFCgYeEdaEOe4cAn+c0RvQMUPyNL+qTOIhswo/3ERMDWuNcpWWe7ygktGsPofmz SXC8eAsJZ9NvJzYpor068mHTR0Nz6Sr8QjCNczqUnE1sP27HPr7EkDJjkYJhV7BvNCE6 EN9mY40E2TbFJfP88AVAK9rkGtxigifAToKjs=
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1764911973; x=1765516773; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=l1pQtBVtb8GselEP6sgwfIIPtuf2xz9Kb17eKElW0aE=; b=g2rxudkuqcOCajASzJNmIPeloB2WU1XAelRJtD/uid1YRL2Ntv45MmC6aC+4tGrTIM 9qnxGUJ29DltOSlnpgAL2Oeooi9YVaoUTGBDT6/MkZdaAlq07NxchfKtH6JuBXlrzejS 8eohxWSfSnjgHS3+I3iYMZqjX25KdCr/wN8xOqEi+QcQGWK95ehJ/sp/KFuOq9KaCGFN D9LpIy88SYM+3amPSWfY2jRyvedyyTKXStPoRDCqQiRbg6vzzBTASfC17Qyy/T3yUGQ5 XyrIAtcHnuL8WDmdjKZgl+46GKiHAklN3REQQzTZ34umbQ3MxvM0WwqCTst6D8EWz8Zr 5Tsw==
X-Forwarded-Encrypted: i=1; AJvYcCXBqQxMsBPVY+8troOL0SloaQfOu8H5PNI8s0xx0pNGlhVu6LRENSGP2wzLxLxApa4iJtlpvSNF2pPV@ietf.org
X-Gm-Message-State: AOJu0YxpyeudDc0xAshWHJ4Ya7V8k3hdVLUc/WyrWtXEjBFcHv9Jj24+ OQe7c6Ai0ksmCiBiWZkjlzPN3Az6Y4RtX1QfmbHMuNmeth+7fvHHpH5Q1QwGBGmVQYp4B4y70tK EJPDWT8xPUzn/g63GlnT8m4V3bs264pycPU2ejZL/vA==
X-Gm-Gg: ASbGncvwgztHEC1O4iLXMWmHFTwReVyt12nI4vTrQRW/9pUxXLD92/NR1cRNfneksSv CfLPCtA0yrEzzRvMjTv9fLA4+s7JBYdoEcgLXW53iudvPn8+OMfEjxDlyximEBcXTxkC8Lx0nxm 2mZ7i9CEmHdoNJWIy4RgQ9njIY8P7xctXkyZVZJJ+71GldzmHAYlf37mzgPNy8YgBNvhiFhvxCI SuX3dXwOFsKq2WLLsQvO3X/Tf9rAjLVggDu5Q4M+Nv5Ir1TIqcg6natpn/kUARO3WZP326Kf4F4 fpd2joSQvQPOiuBp56qAsKojwPk=
X-Google-Smtp-Source: AGHT+IGqMhjf8VMLWVoo2iREY63JcJ6AXTZ0HF6CRxILyCEJSDFGjaYU2AR1PWHQV7WdiiJPNdmZf8ReRGQmVlNYKq0=
X-Received: by 2002:a17:90b:4a8b:b0:341:194:5e7a with SMTP id 98e67ed59e1d1-349127fdfd5mr10262048a91.29.1764911972980; Thu, 04 Dec 2025 21:19:32 -0800 (PST)
Received: from 1064022179695 named unknown by gmailapi.google.com with HTTPREST; Thu, 4 Dec 2025 21:19:32 -0800
Received: from 1064022179695 named unknown by gmailapi.google.com with HTTPREST; Thu, 4 Dec 2025 23:19:28 -0600
MIME-Version: 1.0 (Mimestream 1.8.3)
References: <04751771-27b6-4894-81dc-82036aeea5d2@betaapp.fastmail.com> <0100019ab804a507-449eb08e-87a3-4afc-bb98-9b67827bf928-000000@email.amazonses.com> <05d03d11-f140-461e-8a68-0dd6f1bfe465@it.aoyama.ac.jp> <FRWPR07MB106228FC36F536D383AEEE6A5A2DDA@FRWPR07MB10622.eurprd07.prod.outlook.com> <331d1f14-8ae6-41b7-810d-a21c3a5a5041@it.aoyama.ac.jp> <0100019ae08ae5d4-27a4240b-c315-4363-b79c-2fb80a81eb9f-000000@email.amazonses.com> <8679986b-f7c5-4621-bd04-b970b90ce426@betaapp.fastmail.com> <0100019ae59947ac-edb18e77-10fb-4adf-8e18-da9fe0ee7a01-000000@email.amazonses.com> <fd64b5cb-a74f-4ba0-8469-7a84f127e518@betaapp.fastmail.com> <0100019ae9d410b7-65ca59e5-f278-43b4-a9d7-b269bf5dc61c-000000@email.amazonses.com> <8dd16b2f-81ca-4ce9-9e1e-fbca46f5e7e8@betaapp.fastmail.com> <42D314EB-FA59-46DD-9754-D732BDF92309@gmail.com> <0100019aebc629fc-457e7f9d-101d-4c36-b266-b2d3492ec20c-000000@email.amazonses.com> <57829c0f-b80c-419c-b93c-798a91b64e17@betaapp.fastmail.com> <0100019aec611c59-38479937-c3a9-42c6-ba7b-d336cf84d846-000000@email.amazonses.com>
In-Reply-To: <0100019aec611c59-38479937-c3a9-42c6-ba7b-d336cf84d846-000000@email.amazonses.com>
From: Tim Bray <tbray@textuality.com>
Date: Thu, 04 Dec 2025 21:19:32 -0800
X-Gm-Features: AWmQ_bkXLRCJw4ECF0sEUgWjManOjZmZSzz2GL_c1ho_3w-yY1QR_2V4bH76XiY
Message-ID: <CAHBU6iv6EfX=zGbAG+S11X4Qke=2X3ju3CntHPZMHW3CMv8voQ@mail.gmail.com>
To: Kent Watsen <kent+ietf@watsen.net>
Content-Type: multipart/alternative; boundary="00000000000035a93006452d9740"
Message-ID-Hash: PRUVIR3H3V2MGIUKWENJDZYH5ECDFNIB
X-Message-ID-Hash: PRUVIR3H3V2MGIUKWENJDZYH5ECDFNIB
X-MailFrom: tbray@textuality.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-uri-review.ietf.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: Mahesh Jethanandani <mjethanandani@gmail.com>, tom petch <ietfa@btconnect.com>, "art@ietf.org" <art@ietf.org>, "uri@w3.org" <uri@w3.org>, "uri-review@ietf.org" <uri-review@ietf.org>, Martin Thomson <mt@lowentropy.net>
X-Mailman-Version: 3.3.9rc6
Precedence: list
Subject: [Uri-review] Re: [art] Alternative representation of URIs in YANG
List-Id: Proposed URI Schemes <uri-review.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/uri-review/Vnb5h4i8yYqPtLfZq1KmTBpnKDY>
List-Archive: <https://mailarchive.ietf.org/arch/browse/uri-review>
List-Help: <mailto:uri-review-request@ietf.org?subject=help>
List-Owner: <mailto:uri-review-owner@ietf.org>
List-Post: <mailto:uri-review@ietf.org>
List-Subscribe: <mailto:uri-review-join@ietf.org>
List-Unsubscribe: <mailto:uri-review-leave@ietf.org>
I think the reason that you’re running into friction is that what you’re doing feels weird to people who think about Web architecture. A core premise is that URIs are short-ish strings and that most software in most software doesn’t need to and in fact SHOULD NOT poke around inside them. These strings are the keys into the Web’s vast and flat information space, and they have proved to be highly successful for integrating wildly diverse things together. In practice, what can you actually *do* with a URI? You can compare it to another URI (super important for supporting caching) and you can feed it to an API, many of the most successful being RESTfully flavored and all of them taking URI strings as input. There are libraries in basically every programming language that can parse and validate and try to retrieve or update whatever it is a URI (expressed as a string) identifies. I guess specifying a minimum list of URI schemes is OK, but having a maximum, i.e. limiting the allowed schemes, is likely not a good idea because new ones come along and occasionally are useful. Your expressing them as a structure is going to make comparing them more difficult than it is for strings. There’s more to comparing URIs than you might think, see https://datatracker.ietf.org/doc/html/rfc3986#section-6 I appreciate that this all may sound a bit vague and arm-wavy but my feeling is that URIs are specified as strings and are passed to APIs as strings and any expression that is not a string is thus a bit jarring. -Tim On Dec 4, 2025 at 6:39:38 PM, Kent Watsen <kent+ietf@watsen.net> wrote: > > > On Dec 4, 2025, at 7:08 PM, Martin Thomson <mt@lowentropy.net> wrote: > > A URL is a URI that is also a locator. That is, if you can resolve it, it > will lead you to something. > > > Yes, locators is our primary interest. We have zero interest in URNs. > > > Those are definitely more likely to use the same authority form that HTTP > does, but there isn't a firm guarantee. > > > Grrr > > > The only safe container for a URI generically is a sequence of bytes or > characters (the difference between each is important in many cases, but not > here). The same is generically true for URLs as well, though under certain > narrower definitions it might be safe to carry them in other ways. See > https://url.spec.whatwg.org/ for an example of one such narrow > definition. However, that definition includes file: and blob: URLs, which > are more complicated than you might like. > > > Egads, I don't see an out yet. > > Context: > - The must-have schemes are http: and https: > - The nice-to-have schemes include file:, ftp:, scp:, and mailto: > - Lesser nice-to-haves include: ws: wss: > - No interest in the blob: scheme > > FWIW, in the YANG module, it is possible to make the "scheme" field be an > enumeration. That is, the scheme can be locked down to any subset of the > above. > > Is there a suitable name for some subset of the above? How about: > > - constrained-url > - structured-url > - decomposed-url > - http-and-https-url > - any other suggestion, besides a sequence of bytes or characters ;) > > > Kent > > > _______________________________________________ > Uri-review mailing list -- uri-review@ietf.org > To unsubscribe send an email to uri-review-leave@ietf.org >
- [Uri-review] Re: [art] Re: Alternative representa… Martin J. Dürst
- [Uri-review] Re: [art] Re: Alternative representa… tom petch
- [Uri-review] Re: [art] Alternative representation… Kent Watsen
- [Uri-review] Re: [art] Alternative representation… Martin Thomson
- [Uri-review] Re: [art] Re: Alternative representa… Martin J. Dürst
- [Uri-review] Re: [art] Alternative representation… Kent Watsen
- [Uri-review] Re: [art] Alternative representation… Martin Thomson
- [Uri-review] Re: [art] Alternative representation… Kent Watsen
- [Uri-review] Re: [art] Alternative representation… Martin Thomson
- [Uri-review] Re: [art] Alternative representation… Kent Watsen
- [Uri-review] Re: [art] Alternative representation… Martin Thomson
- [Uri-review] Re: [art] Alternative representation… Mahesh Jethanandani
- [Uri-review] Re: [art] Alternative representation… Kent Watsen
- [Uri-review] Re: [art] Alternative representation… Tim Bray
- [Uri-review] Re: [art] Re: Re: Alternative repres… worley
- [Uri-review] Re: [art] Re: Alternative representa… Kent Watsen
- [Uri-review] Re: [art] Alternative representation… worley
- [Uri-review] Re: [art] Re: Alternative representa… worley
- [Uri-review] Re: [art] Re: Alternative representa… Kent Watsen
- [Uri-review] Re: [art] Re: Alternative representa… worley
- [Uri-review] Re: [art] Re: Alternative representa… worley
- [Uri-review] Re: [art] Re: Alternative representa… Martin Thomson
- [Uri-review] Re: [art] Re: Alternative representa… worley
- [Uri-review] Re: [art] Re: Alternative representa… Kent Watsen
- [Uri-review] Re: [art] Re: Alternative representa… Martin Thomson
- [Uri-review] Re: [art] Re: Alternative representa… Tim Bray
- [Uri-review] Re: [art] Re: Alternative representa… Mahesh Jethanandani
- [Uri-review] Re: [art] Re: Alternative representa… Martin Thomson
- [Uri-review] Re: [art] Re: Alternative representa… Henry S. Thompson
- [Uri-review] Re: [art] Alternative representation… Sampo Syreeni
- [Uri-review] Re: [art] Re: Alternative representa… Kent Watsen
- [Uri-review] Re: [art] Re: Alternative representa… Tim Bray
- [Uri-review] Re: [art] Re: Alternative representa… Mahesh Jethanandani
- [Uri-review] Re: [art] Re: Alternative representa… Mark Nottingham
- [Uri-review] Re: [art] Re: Re: Alternative repres… Orie
- [Uri-review] Re: [art] Re: Alternative representa… Mahesh Jethanandani
- [Uri-review] Re: [art] Re: Alternative representa… Kent Watsen
- [Uri-review] Re: [art] Re: Re: Alternative repres… Martin Thomson
- [Uri-review] Re: [art] Re: Alternative representa… Kent Watsen
- [Uri-review] Re: [art] Re: Alternative representa… Martin Thomson
- [Uri-review] Re: [art] Alternative representation… Kent Watsen