Force: To implement a growing cache with a singleton behavior.
Implementation: Using a SFSB for growing cache and writing the handle of the EJB Object onto a JNDI.
My doubts are whether i am bound to have any performance issues here with growing number of user requests.
-
EJB singleton implementation (1 messages)
- Posted by: Web Master
- Posted on: January 26 2003 21:06 EST
Threaded Messages (1)
- EJB singleton implementation by Gal Binyamini on January 27 2003 11:04 EST
-
EJB singleton implementation[ Go to top ]
- Posted by: Gal Binyamini
- Posted on: January 27 2003 11:04 EST
- in response to Web Master
SFSBs are designed to serve one client only. Turning them into a general-purpose server doesn't work, and is probably a bad idea anyway. On a concurrent call, for instance, the App server may just throw an exception when it recognized the new transaction context.
Search the discussion forums and pattern section for EJB singletons, there are quite a few discussions I can remember. Be sure to read through the whole discussion though. Most suggestions I've seen posted here were initially flawed (incompliant with the spec).
Gal