I agree that PUT should be idempotent, but the POST to /rest/index/[indexname] should not create a new index. In stead, if we regard the index as a resource, it should create something within that resource; hence, you can use this to add something to an existing search index (you will probably post some form containing a name and a file attachment, or something similar).
Angelo On Jan 17, 2011, at 4:46 PM, Ivo Ladage-van Doorn wrote: > No, what I meant is that a PUT should not create a new entry upon each > invocation. > > From: amdatu-developers-bounces at amdatu.org > [mailto:amdatu-developers-bounces at amdatu.org] On Behalf Of Marcel Offermans > Sent: maandag 17 januari 2011 16:21 > To: amdatu-developers at amdatu.org > Subject: Re: [Amdatu-developers] Search & index REST API > > On 17 Jan 2011, at 15:32 , Ivo Ladage-van Doorn wrote: > > > For the paging I would implement this the way I did this in the useradmin > REST service. This implementation is quite similar to the page Bram referred > to, but using Atom syndication links instead of proprietary links for HATEOAS. > Regarding PUT/POST for create/update; PUT requests should be idempotent in > contrast to POST requests. So a POST to /rest/index/[indexname] could > potentially create a new index, a PUT can only update an existing entry (if > it exists). > > So you're saying that wikipedia is wrong? > > http://en.wikipedia.org/wiki/Representational_State_Transfer#RESTful_web_services > > Greetings, Marcel > > _______________________________________________ > Amdatu-developers mailing list > Amdatu-developers at amdatu.org > http://lists.amdatu.org/mailman/listinfo/amdatu-developers -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.amdatu.org/pipermail/amdatu-developers/attachments/20110117/e13cd44a/attachment.html

