On Friday 07 May 2010 1:22:07 am Arif Mohd wrote: > Daniel, > > One more question is it possible to implement stateful webservice in CXF > in Object Oriented way as suggested by kawaguchi in his blog > http://weblogs.java.net/blog/kohsuke/archive/2006/10/stateful_web_se.html
Definitely possible to do with CXF. There really are two ways to do it: 1) Using the spring aop stuff, you set the service object to be a session scope object. Spring will automatically handle setting up the session and creating a new instance and such. 2) If you dig into the jaxws:endpoint stuff, there is a way (don't remember how off hand, you would need to dig a bit) to specify a factory of some sort. There is a org.apache.cxf.service.invoker.SessionFactory that can be set to do something very similar to the spring thing above. Hope that helps! -- Daniel Kulp [email protected] http://dankulp.com/blog
