cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Grzegorz Kossakowski <gkossakow...@apache.org>
Subject Re: http headers
Date Mon, 27 Aug 2007 10:04:23 GMT
franco pace pisze:
> Hi Grzegorz,
> 
> I have been using cocoon for quite a while developing REST ish web
> services. REST is now gaining
> great momentum. 

Yes, even in Cocoon community, see this[1] e-mail. There has been some work in Cocoon that
made 2.2
version much REST-friendly than 2.1.

> REST relies heavily on HTTP protocol and in particular
> in returning specific http status codes
> under certain conditions. For example, say I have a pipeline that
> exposes a db row (or resource):
> 
> <map:match pattern="someentity/*" >
> ...
> 
> Here the * would be an id of some sort.
> 
> so i may wish the GET the entity at url -
> http://myhost/cocoon/someentity/104
> 
> I would like for example, to set the http status code to 403 if the
> client does not
> have authority to view the data, and to say 404 if the entity does not
> exist (not found).

Why not to use flowscript for this?

[1] http://article.gmane.org/gmane.text.xml.cocoon.devel/74571

-- 
Grzegorz Kossakowski
http://reflectingonthevicissitudes.wordpress.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message