Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri-get-off-my-lawn-04 (on the IESG telechat this week)
Kent Watsen <kwatsen@juniper.net> Thu, 15 May 2014 15:21 UTC
Return-Path: <kwatsen@juniper.net>
X-Original-To: netconf@ietfa.amsl.com
Delivered-To: netconf@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id AB57E1A0099 for <netconf@ietfa.amsl.com>; Thu, 15 May 2014 08:21:56 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.901
X-Spam-Level:
X-Spam-Status: No, score=-1.901 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=ham
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 upauPGg5syUa for <netconf@ietfa.amsl.com>; Thu, 15 May 2014 08:21:52 -0700 (PDT)
Received: from na01-bn1-obe.outbound.protection.outlook.com (mail-bn1blp0187.outbound.protection.outlook.com [207.46.163.187]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 1324D1A008D for <netconf@ietf.org>; Thu, 15 May 2014 08:21:51 -0700 (PDT)
Received: from CO1PR05MB458.namprd05.prod.outlook.com (10.141.72.140) by CO1PR05MB460.namprd05.prod.outlook.com (10.141.72.152) with Microsoft SMTP Server (TLS) id 15.0.944.11; Thu, 15 May 2014 15:21:42 +0000
Received: from CO1PR05MB458.namprd05.prod.outlook.com ([169.254.10.51]) by CO1PR05MB458.namprd05.prod.outlook.com ([169.254.10.51]) with mapi id 15.00.0944.000; Thu, 15 May 2014 15:21:42 +0000
From: Kent Watsen <kwatsen@juniper.net>
To: Benoit Claise <bclaise@cisco.com>, Andy Bierman <andy@yumaworks.com>
Thread-Topic: [Netconf] RESTCONF and draft-ietf-appsawg-uri-get-off-my-lawn-04 (on the IESG telechat this week)
Thread-Index: AQHPbjTesrzdWmo2rkmRPyjc5i2Otps9kRSAgAAaUoCAAO5HgIAARg6AgAIsroCAAHbbgA==
Date: Thu, 15 May 2014 15:21:42 +0000
Message-ID: <CF9A4A3A.71AEB%kwatsen@juniper.net>
References: <53714FEC.2030709@cisco.com> <CABCOCHQ4LoM_xcRH-j=3gYo_eBcOjnLmifed1HNa7mt5_k8xAQ@mail.gmail.com> <CABCOCHTMRwSh32owC7E_XCmFm6abcVF4cRigPCz9nBo5R7nQcA@mail.gmail.com> <CF97DDB1.6FB67%kwatsen@juniper.net> <CABCOCHQ8BB-dJdu-jwKhVH3k0UzpCvAY+EOJqfa=EBFveB0RUA@mail.gmail.com> <53743F8F.2050308@cisco.com>
In-Reply-To: <53743F8F.2050308@cisco.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
user-agent: Microsoft-MacOutlook/14.4.1.140326
x-originating-ip: [66.129.241.16]
x-forefront-prvs: 0212BDE3BE
x-forefront-antispam-report: SFV:NSPM; SFS:(428001)(164054003)(17383004)(189002)(199002)(377454003)(24454002)(52604005)(16236675002)(74502001)(80022001)(64706001)(74662001)(20776003)(31966008)(79102001)(77982001)(76482001)(46102001)(81342001)(2656002)(36756003)(87936001)(50986999)(76176999)(81542001)(54356999)(4396001)(83322001)(19580405001)(99286001)(99396002)(83072002)(85852003)(86362001)(92566001)(92726001)(19580395003)(83506001)(101416001)(15202345003)(15975445006)(21056001)(166863002); DIR:OUT; SFP:; SCL:1; SRVR:CO1PR05MB460; H:CO1PR05MB458.namprd05.prod.outlook.com; FPR:; MLV:sfv; PTR:InfoNoRecords; MX:1; A:1; LANG:en;
received-spf: None (: juniper.net does not designate permitted sender hosts)
authentication-results: spf=none (sender IP is ) smtp.mailfrom=kwatsen@juniper.net;
Content-Type: multipart/alternative; boundary="_000_CF9A4A3A71AEBkwatsenjunipernet_"
MIME-Version: 1.0
X-OriginatorOrg: juniper.net
Archived-At: http://mailarchive.ietf.org/arch/msg/netconf/fED77z1LYwbucOdkv5VPXVucflE
Cc: Mark Nottingham <mnot@mnot.net>, 'Barry Leiba' <barryleiba@computer.org>, NETCONF <netconf@ietf.org>
Subject: Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri-get-off-my-lawn-04 (on the IESG telechat this week)
X-BeenThere: netconf@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Network Configuration WG mailing list <netconf.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netconf>, <mailto:netconf-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/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, 15 May 2014 15:21:56 -0000
Hi Mark, thanks for looking in on this! Currently RESTCONF hardcodes the top-level URL path "/restconf", which isn't in line with your BCP. Our thoughts are to put in text like that below. Looking at rfc6570, I don't see how URI templates would help here. Can you suggest a better way? - or were you thinking that we could use URI Templates to define the structure of the RESTCONF API's URLs? Thanks, Kent =====START===== RESTCONF Path Resolution In line the best practices defined by "get-off-my-lawn", RESTCONF enables deployments to specify where the RESTCONF API is located. When first connecting to a RESTCONF server, a RESTCONF client MUST determine the root of the RESTCONF API. The client discovers this by getting the ".well-known/host-meta" resource [RFC6415] as follows: Request ------- GET /.well-known/host-meta users HTTP/1.1 Host: example.com Accept: application/xrd+xml Response -------- HTTP/1.1 200 OK Content-Type: application/xrd+xml Content-Length: nnn <XRD xmlns='http://docs.oasis-open.org/ns/xri/xrd-1.0'> <Link rel='restconf' href='/api/restconf'/> </XRD> Once discovering the RESTCONF API root, the client MUST prepend it to any access to a RESTCONF resource. For instance, using the "/api/restconf" path discovered above, the client can now determine the version of RESTCONF protocol as follows: Request ------- GET /api/restconf/version HTTP/1.1 Host: example.com Accept: application/yang.api+json Response -------- HTTP/1.1 200 OK Date: Mon, 23 Apr 2012 17:01:00 GMT Server: example-server Cache-Control: no-cache Pragma: no-cache Last-Modified: Sun, 22 Apr 2012 01:00:14 GMT Content-Type: application/yang.api+json { "version": "1.0" } ===== STOP ===== From: Benoit Claise <bclaise@cisco.com<mailto:bclaise@cisco.com>> Date: Thursday, May 15, 2014 at 12:16 AM To: Andy Bierman <andy@yumaworks.com<mailto:andy@yumaworks.com>>, Kent Watsen <kwatsen@juniper.net<mailto:kwatsen@juniper.net>> Cc: NetConf <netconf@ietf.org<mailto:netconf@ietf.org>>, 'Barry Leiba' <barryleiba@computer.org<mailto:barryleiba@computer.org>>, Mark Nottingham <mnot@mnot.net<mailto:mnot@mnot.net>> Subject: Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri-get-off-my-lawn-04 (on the IESG telechat this week) Dear all, Discussing this issue with Barry: Yes, .well-known is a possible solution for netconf/restconf. Another possibility is URI templates. The get-off-my-lawn document talks about both. For restconf, Mark Nottingham could help advise which would be a better option for them. Regards, Benoit On Tue, May 13, 2014 at 11:53 AM, Kent Watsen <kwatsen@juniper.net<mailto:kwatsen@juniper.net>> wrote: Andy writes: I think RESTCONF violates sec 2.3 wrt/ structure within the URI path. <snip/> I agree with Andy that RESTCONF violates section 2.3. I also think that we can remove that violation by supporting "well-known" URIs. Notice that the 2nd paragraph in section 2.3 says "The only exception to this requirement is registered 'well-known' URIs, as specified by [RFC5785]." My reading is, if we use a "well-known" URI, then our subtree can defined sub-structure per RESTCONF convention. We discussed using well-known URIs before. Appendix B.3. in the RESTCONF draft ("Open Issues") regards ".well-known usage". This issue was closed with the resolution "not needed in RESTCONF". We may need to revisit that decision now. I agree we need to support .well-known to conform to this BCP. Thanks, Kent Andy
- [Netconf] RESTCONF and draft-ietf-appsawg-uri-get… Benoit Claise
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Andy Bierman
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Andy Bierman
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Kent Watsen
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Andy Bierman
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Benoit Claise
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Kent Watsen
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Kent Watsen
- Re: [Netconf] RESTCONF and draft-ietf-appsawg-uri… Mark Nottingham