Hi Daid,
>
> (It turns out the JAX-RS spec is unusually short and comprehensible,
> which is unusual for these enterprisey specs.  The downside is that
> it's short partly because they left out a little too much, and JAX-RS
> is essentially not a stand-alone technology, you pretty much need some
> sort of injection container around it, which the spec ignores, 
BTW: that's the same in Restlet: you need a container, that calls the 
Filters, the Resources and so on. Here it is the Restlet Engine and so 
on, and there it is a JAX-RS container. What's the difference?
> and therefore there's effectively no way to write portable jax-rs code for
> any application that does anything interesting, like accessing stored
> data, for instance.)
>   
Why you can't write portable applications? You could e.g. use JDBC or 
Hibernate. That's portable, or why not?
> And one problem for people trying to automate the mapping of requests
> onto java methods is that, until recently, java methods didn't provide
> much in the way of places to stick data about themselves.
That's annotations are made for. But I think, you know it :-), and I 
miss or missunderstand something.

> I did a number of experiments comparing how to implement the same
> resources in Restlet and in Jax-RS, and for the most part the only
> difference was the presence of this routing code in the Restlet
> version, which got replaced by a couple of easy-to-understand
> annotations.
>   
Right, IMO (also as member of the JAX-RS expert group and developer of 
the JAX-RS extension).
The routing code is boilerplate code. It is needed, if you don't use 
something like annotations. And because boilerplate code induces bugs, 
so avoid the need for it.

best regards
   Stephan

------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=1648220

Reply via email to