Re: [apps-discuss] more feature requests, was: JSON patch: "test" operation

Sam Johnston <samj@samj.net> Fri, 30 December 2011 14:06 UTC

Return-Path: <samj@samj.net>
X-Original-To: apps-discuss@ietfa.amsl.com
Delivered-To: apps-discuss@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id F38FA21F8BE5 for <apps-discuss@ietfa.amsl.com>; Fri, 30 Dec 2011 06:06:39 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -5.698
X-Spam-Level:
X-Spam-Status: No, score=-5.698 tagged_above=-999 required=5 tests=[AWL=0.278, BAYES_00=-2.599, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_MED=-4]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DXS-+UC0tccO for <apps-discuss@ietfa.amsl.com>; Fri, 30 Dec 2011 06:06:20 -0800 (PST)
Received: from eu1sys200aog109.obsmtp.com (eu1sys200aog109.obsmtp.com [207.126.144.127]) by ietfa.amsl.com (Postfix) with ESMTP id 6652721F8BDC for <apps-discuss@ietf.org>; Fri, 30 Dec 2011 06:06:18 -0800 (PST)
Received: from mail-yw0-f41.google.com ([209.85.213.41]) (using TLSv1) by eu1sys200aob109.postini.com ([207.126.147.11]) with SMTP ID DSNKTv3FSUZeEAR7BmTOUR/ahVtnayhP5oSs@postini.com; Fri, 30 Dec 2011 14:06:19 UTC
Received: by yhgm50 with SMTP id m50so7641916yhg.0 for <apps-discuss@ietf.org>; Fri, 30 Dec 2011 06:06:00 -0800 (PST)
Received: by 10.236.128.197 with SMTP id f45mr50910316yhi.44.1325253960408; Fri, 30 Dec 2011 06:06:00 -0800 (PST)
MIME-Version: 1.0
Received: by 10.236.143.100 with HTTP; Fri, 30 Dec 2011 06:05:39 -0800 (PST)
In-Reply-To: <4EFDAABF.7020804@gmx.de>
References: <4ED64A26.5030003@gmx.de> <BC564D94-6D00-4D63-863A-8AAD00E57B3A@tzi.org> <4ED77513.3070506@gmx.de> <6E443D75-D1AC-451F-9B17-115C9A6C7696@mnot.net> <4ED7F8C2.9030804@gmx.de> <37E09A53-E9F4-45D2-BB8F-79655BECDBB2@mnot.net> <1322779521.1958.1.camel@neutron> <4EFC8A08.7000105@gmx.de> <1325222688.18477.25.camel@neutron> <CAKTR03_GdgdTwJF073uV1iUGSEW1E6wXxO-OtYpWReARBhRMgQ@mail.gmail.com> <4EFD954B.3090006@gmx.de> <CAKTR03_XZOW3HK4MLjG8n+-SmCBp68Zym4S-g6vj3NXa-=kHfQ@mail.gmail.com> <4EFDAABF.7020804@gmx.de>
From: Sam Johnston <samj@samj.net>
Date: Fri, 30 Dec 2011 15:05:39 +0100
Message-ID: <CAKTR039MLM=QKo0xOJewbVqspuTpm82z_wSw3WF=CD9dao-a8g@mail.gmail.com>
To: Julian Reschke <julian.reschke@gmx.de>
Content-Type: multipart/alternative; boundary=20cf300fb37d8c1f0e04b54fbbfc
Cc: IETF Apps Discuss <apps-discuss@ietf.org>
Subject: Re: [apps-discuss] more feature requests, was: JSON patch: "test" operation
X-BeenThere: apps-discuss@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: General discussion of application-layer protocols <apps-discuss.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/apps-discuss>
List-Post: <mailto:apps-discuss@ietf.org>
List-Help: <mailto:apps-discuss-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 30 Dec 2011 14:06:40 -0000

On Fri, Dec 30, 2011 at 1:12 PM, Julian Reschke <julian.reschke@gmx.de>wrote;wrote:

> On 2011-12-30 12:36, Sam Johnston wrote:
> > ...
>
>>    Of course that depends on how you define the lifetime of a resource.
>>    Does a resource which currently doesn't have a retrievable
>>    representation "exist"?
>>
>>    Technically, PATCH can work for creating an initial mapping as well.
>>
>> That's a contrived interpretation — is it something we want to support?
>> I'd rather a PATCH throw a 4xx error if a resource didn't exist... an
>> empty PUT would create a resource that could then be PATCHed, no?
>> ...
>>
>
> It probably belongs into the description of the patch format.
>

Agreed.


>  I don't see how requiring an empty PUT makes things better, though.
>

It would prevent misplaced PATCHes from creating new resources, while still
allowing you to build up a resource from scratch with PATCHes. Maybe I'm
being pedantic, but I thought that's what standards groups were for ;)

Sam