Re: [Netconf] Long-lasting RESTCONF operations

"Uveges, Balint (Nokia - HU/Budapest)" <balint.uveges@nokia.com> Fri, 02 October 2015 13:27 UTC

Return-Path: <balint.uveges@nokia.com>
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 C90FA1A8A3D for <netconf@ietfa.amsl.com>; Fri, 2 Oct 2015 06:27:16 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -6.901
X-Spam-Level:
X-Spam-Status: No, score=-6.901 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, 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 TmGjMA0kw7fO for <netconf@ietfa.amsl.com>; Fri, 2 Oct 2015 06:27:10 -0700 (PDT)
Received: from demumfd002.nsn-inter.net (demumfd002.nsn-inter.net [93.183.12.31]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 32D901A910B for <netconf@ietf.org>; Fri, 2 Oct 2015 06:27:09 -0700 (PDT)
Received: from demuprx016.emea.nsn-intra.net ([10.150.129.55]) by demumfd002.nsn-inter.net (8.15.2/8.15.2) with ESMTPS id t92DR7Vd012537 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 2 Oct 2015 13:27:08 GMT
Received: from DEMUHTC002.nsn-intra.net ([10.159.42.33]) by demuprx016.emea.nsn-intra.net (8.12.11.20060308/8.12.11) with ESMTP id t92DR5Cc027936 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=FAIL); Fri, 2 Oct 2015 15:27:06 +0200
Received: from DEMUHTC014.nsn-intra.net (10.159.42.45) by DEMUHTC002.nsn-intra.net (10.159.42.33) with Microsoft SMTP Server (TLS) id 14.3.248.2; Fri, 2 Oct 2015 15:27:05 +0200
Received: from DEMUMBX006.nsn-intra.net ([169.254.6.213]) by DEMUHTC014.nsn-intra.net ([10.159.42.45]) with mapi id 14.03.0248.002; Fri, 2 Oct 2015 15:27:05 +0200
From: "Uveges, Balint (Nokia - HU/Budapest)" <balint.uveges@nokia.com>
To: EXT Andy Bierman <andy@yumaworks.com>
Thread-Topic: [Netconf] Long-lasting RESTCONF operations
Thread-Index: AdD2qlN3N/lWCzBIQVO6Z0AWvW6WZAALB++AAPYv1rA=
Date: Fri, 02 Oct 2015 13:27:04 +0000
Message-ID: <28B876C36C5AA84CBAB912BA734FAC350164B30B@DEMUMBX006.nsn-intra.net>
References: <28B876C36C5AA84CBAB912BA734FAC35016469DA@DEMUMBX006.nsn-intra.net> <CABCOCHTAHRUqkKitwDAczG3utLi8BtX_r2_Z4ncVj7jT_W7-yg@mail.gmail.com>
In-Reply-To: <CABCOCHTAHRUqkKitwDAczG3utLi8BtX_r2_Z4ncVj7jT_W7-yg@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [10.159.42.126]
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-purgate-type: clean
X-purgate-Ad: Categorized by eleven eXpurgate (R) http://www.eleven.de
X-purgate: clean
X-purgate: This mail is considered clean (visit http://www.eleven.de for further information)
X-purgate-size: 5014
X-purgate-ID: 151667::1443792428-00005272-9D759877/0/0
Archived-At: <http://mailarchive.ietf.org/arch/msg/netconf/oLk3ONt4SFMlOeYY1odJcBXaJtQ>
Cc: "netconf@ietf.org" <netconf@ietf.org>
Subject: Re: [Netconf] Long-lasting RESTCONF operations
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: <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: Fri, 02 Oct 2015 13:27:17 -0000

Hi Andy,

>  From: EXT Andy Bierman [mailto:andy@yumaworks.com] 
>  Sent: Thursday, September 24, 2015 6:37 PM
>  To: Uveges, Balint (Nokia - HU/Budapest)
>  Cc: netconf@ietf.org
>  Subject: Re: [Netconf] Long-lasting RESTCONF operations
>
>
>
> >  On Thu, Sep 24, 2015 at 2:21 AM, Uveges, Balint (Nokia - HU/Budapest) <balint.uveges@nokia.com> wrote:
> >  Hi All,
> >
> >  I would like to clarify an issue regarding the following RESTCONF scenario.
> >
> >  Let's assume that certain RESTCONF operations take quite some time on
> >  the server side, for example the evaluation of a received POST method
> >  (in Create Resource Mode), due to internal validations or due to the
> >  processing of large amount of received data. According to the RESTCONF
> >  draft (section 4.4.1):
> >
> >    "If the POST method succeeds, a "201 Created" status-line is returned
> >     and there is no response message-body."
> >
> >  If I interpret this right, a RESTCONF client has to wait for 201 Created
> >  (or for 4xx/5xx if something goes wrong) no matter how long it takes for
> >  the server to process and answer the POST method. This behavior has no
> >  significance if a RESTCONF client manages only a few RESTCONF server,
> >  but could lead easily to a bottleneck in the client in case of large
> >  amount of RESTCONF servers, when the client manages them in parallel.
> >
> >  RESTCONF is an HTTP-based protocol and RFC 7231 defines the status code
> >  202 Accepted (section 6.3.3) as:
> >
> >    "The 202 (Accepted) status code indicates that the request has been
> >     accepted for processing, but the processing has not been completed.
> >  . . .
> >     The representation sent with this
> >     response ought to describe the request's current status and point to
> >     (or embed) a status monitor that can provide the user with an
> >     estimate of when the request will be fulfilled."
> >
> >  With 202 Accepted it would be possible not just to inform the RESTCONF
> >  client, that the method is accepted and is waiting to be processed but
> >  also the HTTP connection could be terminated (if needed). Moreover it
> >  would provide means for the client to poll the status of the request at
> >  the URI provided in the Location header of 202 Accepted.
> >
> >  Side note: The RESTCONF draft lists the HTTP method 202 Accepted as well
> >  in chapter 7, but it does not define any semantics.  
> >
> > Thank you in advance for your comments.
>
>
>  So you are suggesting that a server can optionally support 202 Accepted,
>  which means of course it is mandatory to support for the client.
>
>  There seems to be some interest in the IETF right now wrt/ clarifying what it
>  means when the server returns <ok/> to an edit request.  If it means "your edit
>  is part of the intended configuration" then 202 Accepted is not really needed as
>  any decent server can do this without delay.  If it means "your edit is now
>  reflected in actual network behavior" then perhaps it will be useful.

The 202 Accepted would mean that the server started to process the edit request.
You're right that a decent server could immediately respond with a 201 Created,
but there are cases where the underlying (and not so decent) system also does
some validation and provisioning work, that could easily delay the whole operation.

The status of the edit request (e.g. is it under processing, applied to the system
or rejected) could be indicated through the status URI that is provided in
the 202 Accepted.


>
>
>   
> >  Best regards,
> >  -Balint
>
>  Andy

Br,
-Balint