> -----Original Message----- > From: Sergey Beryozkin [mailto:[email protected]] > Sent: Thursday, August 27, 2009 5:21 AM > To: [email protected] > Subject: Re: Need more info on configuring JAX-RS without Spring > > I've updated the documentation : > > http://cwiki.apache.org/confluence/display/CXF20DOC/JAX-RS#JAX-RS- > RESTfulserviceswithoutannotations > > David - can you please let me know if it describes things clearly > enough - I'll update it as needed and I'll fix the > CXFNonSpringJaxrsServlet issue shortly
Thanks, I'll go through it today. > ----- Original Message ----- > From: "Sergey Beryozkin" <[email protected]> > To: <[email protected]> > Sent: Thursday, August 27, 2009 10:25 AM > Subject: Re: Need more info on configuring JAX-RS without Spring > > > > CXFNonSpringJaxrsServlet can't do it yet - it's a bit lame given that > at a time I did know I needed to update it too but due to a > > time pressure I decided to do it later on, whenever it would be > needed. I'll fix it, the temp workaround is to extend > > > > CXFNonSpringJaxrsServlet and handle a servlet parameter 'user.model' > pretty much exactly the same way it's done in > > JAXRSClientServerUserResourceTest.java : > > > > public class JAXRSUserModelServlet extends CXFNonSpringJaxrsServlet > { > > > > Override > > > > public void loadBus(ServletConfig servletConfig) throws > ServletException { > > > > super.loadBus(servletConfig); > > > > JAXRSServerFactoryBean sf = new JAXRSServerFactoryBean(); > > > > String address = > servletConfig.getInitParameter(SERVICE_ADDRESS_PARAM); //jaxrs.address > > > > if (address == null) { > > > > address = "/"; > > > > } > > > > sf.setAddress(address); > > > > > > // modelRef needs to start from 'classpath:', ex 'classpath:/WEB- > INF/models/model1.xml > > > > String modelRef = servletConfig.getInitParameter("user.model"); > > > > sf.setModelRef(modelRef); > > > > sf.create(); > > > > } > > > > can you try it please ? > > > > By the way, one question I wanted to ask : why is it that we see > @XmlRootElement annotation on Catalog.Items class being available > > at runtime but do not see JAXRS annotations being there during the > init time ? Personally I do like this no-annotations featue but > > I'm just curious why JAXRS annotations can not be seen. Can it be > that annotations are not visible during the spring injection > > time but are available later on at runtime ? Can you may be , just > for test, check the @Path annotation on the Catalog.class in > > the body of getItems() method, as well as @XmlRootElement on Items ? > > > > cheers, Sergey > > > > ----- Original Message ----- > > From: "KARR, DAVID (ATTCINW)" <[email protected]> > > To: <[email protected]> > > Sent: Wednesday, August 26, 2009 6:18 PM > > Subject: RE: Need more info on configuring JAX-RS without Spring > > > > > >> -----Original Message----- > >> From: Sergey Beryozkin [mailto:[email protected]] > >> Sent: Wednesday, August 26, 2009 10:11 AM > >> To: Sergey Beryozkin; [email protected] > >> Subject: Re: Need more info on configuring JAX-RS without Spring > >> > >> In meantime, here is a system test that shows how it can be dome > >> without Spring : > >> > >> > > > http://svn.apache.org/repos/asf/cxf/trunk/systests/src/test/java/org/ap > >> ache/cxf/systest/jaxrs/JAXRSClientServerUserResourceTest.java > > > > Ok, that's without Spring, but it's also using a standalone listener. > > How would you use the CXFServlet (or a variation of that for > NonSpring, > > I believe) in WebLogic, but configuring it without Spring? > > > >> ----- Original Message ----- > >> From: "Sergey Beryozkin" <[email protected]> > >> To: <[email protected]> > >> Sent: Wednesday, August 26, 2009 6:01 PM > >> Subject: Re: Need more info on configuring JAX-RS without Spring > >> > >> > >> > No problems at all - I do have to document it better - I'll do it > > (as > >> well as DOSGO docs updates I promised to do today) the first > >> > thing tomorrow morning (with a clear head :-)). > >> > Hope the info I provided in the prev email will help a bit - I > might > >> also check the emails later today... > >> > > >> > Sergey > >> > > >> > ----- Original Message ----- > >> > From: "KARR, DAVID (ATTCINW)" <[email protected]> > >> > To: <[email protected]> > >> > Sent: Wednesday, August 26, 2009 5:37 PM > >> > Subject: Need more info on configuring JAX-RS without Spring > >> > > >> > > >> > Much as I hate to ask this, I need to get more info about how to > >> > configure JAX-RS services WITHOUT Spring, and without annotations. > >> > > >> > The manual has some high-level information about this, but not at > > the > >> > level of the model or resources. For instance, it talks about > using > >> the > >> > JAXRSServerFactoryBean to set some high-level info, but nothing > > below > >> > the resource class itself, and nothing specifying paths. > >
