Re: MKCOL for making collections

On 22 Jan 2013, at 16:58, Alexandre Bertails <bertails@w3.org> wrote:

> On 01/22/2013 10:52 AM, Steve Speicher wrote:
>> On Tue, Jan 22, 2013 at 10:35 AM, Alexandre Bertails <bertails@w3.org> wrote:
>>> On 01/22/2013 10:17 AM, Steve Speicher wrote:
>>>> 
>>>> On Tue, Jan 22, 2013 at 10:03 AM, Henry Story <henry.story@bblfish.net>
>>>> wrote:
>>>>> 
>>>>> ISSUE-36: Can applications create new containers?
>>>>> 
>>>>> We cannot make a collection by POSTing a doument on a collection, since
>>>>> that
>>>>> creates a resource. We therefore would need a different HTTP Method to do
>>>>> this.
>>>>> 
>>>> 
>>>> Why can't we do this?  A Container/Collection IS a resource.  So
>>>> therefore POST'ing the representation of it seems like the most
>>>> obvious way to create one.
>>> 
>>> 
>>> I agree with Henry's premises: this way of creating containers should
>>> be discussed. The reason is that this strategy forces you to look into
>>> each RDF document that is POSTed, to search for the triples saying
>>> "hey, by the way, I'm an LDPC!".
>>> 
>>> It's not that it's impossible, it's just very annoying in practice. So
>>> it's at least not perfect.
>>> 
>>> Alexandre.
>>> 
>> 
>> That reasoning makes sense but doesn't avoid the case where a server
>> receives a RDF document with a "new" container in it and needs to sort
>> out what to make of it.  Worth discussing I agree, I see pros and cons
>> to both approaches.
> 
> Using a different verb (or just something different enough from
> POSTing a new LDPR), the server can at least make a choice of actions
> *before* looking at the content. That's a pro.
> 
> Also in practice, the server will probably want to look at the RDF
> content, to check if it's valid RDF for example. Not really a pro or a
> cons, just to say that we're doomed anyway :-)

Oh no! A devil just came up from the underworld and whispered to me:
 
  "of course you would not have this trouble if all collections were
   URIs that ended with a '/' "


> Alexandre.
> 
>> 
>>> 
>>>> 
>>>>> I suggest MKCOL from WebDAV, since it is already defined.
>>>>> 
>>>>> 
>>>>>     http://restpatterns.org/HTTP_Methods/MKCOL
>>>>> 
>>>>> 
>>>>> The content of the body, could be Triples that describe things
>>>>> that can be put into the collection. As it happens that is not
>>>>> defined yet it seems, so we can define it.
>>>>> 
>>>>>    Any thoughts on that?  I'll try implementing that.
>>>>> 
>>>> 
>>>> Seems like we'd have to dig into more of what the semantics of that
>>>> verb says [1] but feels a little like we'd have to adapt more of
>>>> WebDAV instead of just reusing the verb and giving it our own special
>>>> meaning.
>>>> 
>>>> [1] - http://www.webdav.org/specs/rfc2518.html#METHOD_MKCOL
>>>> 
>>>>> Henry
>>>>> 
>>>>> Social Web Architect
>>>>> http://bblfish.net/
>>>>> 
>>>> 
>>>> 
>>>> 
>>>> --
>>>> - Steve
>>>> 
>>>> 
>>> 
>>> 
>> 
>> 
>> 
>> --
>> - Steve
>> 
> 
> 

Social Web Architect
http://bblfish.net/

Received on Tuesday, 22 January 2013 16:04:44 UTC