This content has been marked as final.
Show 1 reply
-
1. Re: Singleton and JBoss / J2EE
manavagiwal Jul 31, 2003 2:49 AM (in response to sharon_benaim)J2EE specs discourages people to use static modifier and synchronised keyword for methods which are vital for implementing the singleton pattern. Encouraging this has an impact on Bean pooling and caching. It doesnot mean that it is wrong to implement singleton with EJBs Pattern. It should just be done right.
JBoss comes with classes that help you implement singleton pattern. You can deploy an MBean which has a single instance running in the whoke cluster. Take a look at this article.
http://www.cocoonhive.org/articles/jboss/20030610/hasingleton.html
Hope that helps.
Manav