|
From: Ian B. <ibu...@re...> - 2008-06-03 14:41:25
|
Bill, Thanks for the responses. I have managed to hook up an application context fine. My question was, after I have an ApplicationContext how do I hook those into my Resource Classes? From the spec it looks like the authors are anticipating a JEE deployment. "JAX-RS root resource classes and providers are supplied with the same resource injection capabilities 22 as are provided for a Servlet instance running in a Java EE Web container. In particular the follow- 23 ing annotations may be used according to their individual semantics: @Resource, @Resources, @EJB, 24 @EJBs, @WebServiceRef, @WebServiceRefs, @PersistenceContext, @PersistenceContexts, 25 @PersistenceUnit and @PersistenceUnits. " So it looks like if I had a JEE 6 container I could wire in and EJB or web service. Is there something I can do now to wire in a Spring Bean? Thanks, Ian. On Jun 2, 2008, at 10:22 PM, Bill Burke wrote: > Does this help shed some light? > > http://wiki.jboss.org/wiki/RESTeasySpringIntegration > > > > Ian Butcher wrote: >> I am having some trouble connecting the dots. From the JAX-RS >> Spec it's clear that normally a new Resource Class is created for >> each request. I have convinced myself that the Resource Classes >> are something like endpoints or Struts actions; they get their >> model from the Provider and the scoping information from the >> injected annotation arguments. >> Coming from a Spring and web service background this is where I'd >> normally wire in a domain repositories and services. This >> doesn't seem to fit the model of having a new Resource Class per >> request. Can someone explain the right mental model for this? >> Thanks, >> Ian. >> ------------------------------------------------------------------------- >> This SF.net email is sponsored by: Microsoft >> Defy all challenges. Microsoft(R) Visual Studio 2008. >> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ >> _______________________________________________ >> Resteasy-developers mailing list >> Res...@li... >> https://lists.sourceforge.net/lists/listinfo/resteasy-developers > > -- > Bill Burke > JBoss, a division of Red Hat > http://bill.burkecentral.com |