Skip to main content

How to create a @Singleton bean that implements a WebService...

1 reply [Last post]
simgineer
Offline
Joined: 2011-03-21
Points: 0

I want to convert my webservice which is @WebService;@Stateless implementation into a @Singleton bean but when i add in the @Singleton annotation and deploy glassfish flags a severe error: Annotations processing failed for...

so i tried removing the webservice/stateless and replaced it with the @Singleton annotation but now it does not appear to deploy as a webservice at all. I have an interface that is marked up with @WebService and @WebMethod and this new @Singleton class implements it...

Any advice or help is greately appreciated.

below are some links which led me to believe Singleton beans can be used in the manner i'm trying to use them.

http://openejb.apache.org/3.0/singleton-beans.html

http://download.oracle.com/javaee/6/tutorial/doc/gipjg.html

"Singleton session beans offer similar functionality to stateless session beans but differ from them in that there is only one singleton session bean per application, as opposed to a pool of stateless session beans, any of which may respond to a client request. Like stateless session beans, singleton session beans can implement web service endpoints."

James Chan

AttachmentSize
SingletonWebServiceCompatibility.PNG14.64 KB

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
simgineer
Offline
Joined: 2011-03-21
Points: 0