users@jersey.java.net

Re: [Jersey] Jersey serving the human web?

From: Lars Tackmann <lars_at_randompage.org>
Date: Fri, 27 Mar 2009 13:35:15 +0100

On Fri, Mar 27, 2009 at 1:04 PM, Casper Bang <casper_at_jbr.dk> wrote:
> O'Reilly's RESTful Web Services suggests one representation of a resource
> could be for the human web, i.e. serving application/xhtml+xml or even
> text/html for people to use directly. While I realize creating webpages
> (however simple) is not the focus of REST or Jersey, I'm trying to combine
> it since I've fallen in love with its simplicity (having had painful
> encounters with gigantic and complex JSF stacks in the past).
>
> One problem with this however is that I'm finding myself either writing
> html/css/javascript inside Java Strings and/or serving JSP. I wonder if
> others have taken this path before and if they have any
> recommendations/experiences to share? I expect one possible answer is not to
> do it, but rather create another layer for the human web that simple
> consumes the resources. However, I can't help feeling that there could be
> space for a simpe human web framework on top of Jersey at a provider level.
> Am I wrong?
>
> Thanks in advance,
> Casper
>

I have deployed application/xhtml+xml via Jersey commercially in the
Danish telecom industry using XSLT with great success.
The client code was written in prototype and recived the XML/XHTML
representations from Jersey resources.

I personally dislike using JSP/JSF for the task of generating XHTML in
a RESTful webapp as it seams to complicate things neadlessly


-- 
Yours sincerely
Lars Tackmann