Hi Reza,
It would indeed seem odd if JAX-RS would not have such functionality.
The plan is to produce a maintenance release of JAX-RS that aligns
with EE 6.
With respect to Jersey you can obtain EE functionality for JAX-RS
resource classes by using Spring [1]. In fact for EE 6 integration the
current plan is to use WebBeans.
IMHO the use of EJBs defined to be JAX-RS resources may be somewhat
limited because (session) EJBs are designed for RCP-style interactions
(CORBA, WS-*) thus resource methods may not make any sense in terms of
equivalent calls using CORBA. What is more interesting is reusing some
of the capabilities of EJBs. Having said that i think something should
be possible, there may be two ways:
1) You can extend the Jersey servlet to register singleton instances
of annotated EJBs obtain using JNDI lookup.
2) The Jersey servlet when in an EE environment could perform look up
of registered classes using JNDI with
class names as the JNDI names, and if instances exist register
those as singleton instances.
Paul.
On Sep 7, 2008, at 7:07 PM, Reza Rahman wrote:
> Hi,
>
> I am wondering if there are any concrete plans on supporting JAX-RS
> annotations on EJB 3 Beans, perhaps as part of project GlassFish? I
> am looking for something in the flavor that the JBoss implementing
> RESTEasy, supports in terms of EJB 3/JAX-RS integration? Since such
> integration already exists between JAX-WS and EJB 3, it seems odd
> that JAX-RS should not have the same?
>
> Thanks in advance,
> Reza
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>