[Catalyst] Re: RFC: Catalyst::Controller::REST::DBIC

Zbigniew Lukasiak zzbbyy at gmail.com
Fri May 16 05:19:27 BST 2008


On Thu, May 15, 2008 at 11:11 PM, Aristotle Pagaltzis <pagaltzis at gmx.de> wrote:
> * Zbigniew Lukasiak <zzbbyy at gmail.com> [2008-05-15 21:25]:
>> On Thu, May 15, 2008 at 7:31 PM, Mark Trostler <mark at zzo.com> wrote:
>> > Similarly you don't need 'id' in the url - so POST to
>> > /api/rest/cd will create a cd.  A PUT to /api/rest/cd/5 will
>> > update that CD - a DELETE to /api/rest/cd/5 will delete that
>> > CD...
>>
>> Additionally we would like to have other non REST actions in
>> the same controller. This mixing will require some separation
>> between the method names and the object id (which is data).
>
> You are thinking about it wrong. You don't put method names into
> the URI; you expose more of the state as things to manipulate.
>
> If you give an example of what you mean I can give you one of
> what I mean.

Hmm - frankly I have never thought out REST entirely - but I have the
feeling that it is always better to be cautious (and you know - be
liberal in what you receive).  Some ideas top of my head:

- a login method (the advantage would be that it does not need to redirect)

- a search

- exposing some class data (as opposed to instance data) and maybe
class methods?

Cheers,
Zbigniew Lukasiak
http://brudnopis.blogspot.com/



More information about the Catalyst mailing list