- From: Raúl García Castro <rgarcia@fi.upm.es>
- Date: Fri, 19 Oct 2012 11:07:28 +0200
- To: Steve Battle <steve.battle@sysemia.co.uk>
- CC: "'Linked Data Platform (LDP) Working Group'" <public-ldp-wg@w3.org>
El 18/10/12 17:17, Steve Battle escribió: > > >> -----Original Message----- >> From: Linked Data Platform (LDP) Working Group Issue Tracker >> [mailto:sysbot+tracker@w3.org] >> Sent: 02 October 2012 15:15 >> To: public-ldp-wg@w3.org >> Subject: ldp-ISSUE-12 (HTTP PATCH for creation): Can HTTP PATCH be used >> for resource creation? [Linked Data Platform core] >> >> ldp-ISSUE-12 (HTTP PATCH for creation): Can HTTP PATCH be used for >> resource creation? [Linked Data Platform core] >> >> http://www.w3.org/2012/ldp/track/issues/12 >> >> Raised by: Raúl García Castro >> On product: Linked Data Platform core >> >> 4.7 + 5.8 (HTTP PATCH) >> >> HTTP PATCH MAY be used to create a new resource if the URI does not point >> to an existing resource. >> >> Are we interested in restricting the usage of PATCH only for updates? Or do >> we allow this behaviour? >> >> > > According to RFC 5789 : PATCH Method for HTTP > > 2. The PATCH Method > > The PATCH method requests that a set of changes described in the > request entity be applied to the resource identified by the Request- > URI. The set of changes is represented in a format called a "patch > document" identified by a media type. If the Request-URI does not > point to an existing resource, the server MAY create a new resource, > depending on the patch document type (whether it can logically modify > a null resource) and permissions, etc. > > So it looks like - YES - the patch method may create a new resource. > The ChangeSet representation, for example seems to support this scenario (assuming we're not trying to delete non-existing existing triples with that subject) <http://www.w3.org/2009/12/rdf-ws/papers/ws07> > In addition, even if the patched resource already exists, the RDF description may include additional resources that don't yet exist which would have to be created. Then, I suggest to update the specification to clarify this, similarly to what is done for using PATCH for updates: "4.7.1 LDPR servers may implement HTTP PATCH to allow modifications, especially partial replacement, of their resources. [RFC5789]" Kind regards, -- Dr. Raúl García Castro http://delicias.dia.fi.upm.es/~rgarcia/ Ontology Engineering Group Departamento de Inteligencia Artificial Universidad Politécnica de Madrid Campus de Montegancedo, s/n - Boadilla del Monte - 28660 Madrid Phone: +34 91 336 36 70 - Fax: +34 91 352 48 19
Received on Friday, 19 October 2012 09:07:52 UTC