Does Stateful Session bean support instance pooling?

Discussions

EJB programming & troubleshooting: Does Stateful Session bean support instance pooling?

  1. Hi All,

    According Richard Monson Haefel's book, stateful session bean conceptually doesn't have instance pooling. But some container implement pooling internally.

    According to Ed Roman, it does support pooling. Can anybody pls tell me what specification says ?

    Any pointer is welcome.

    Regards,
    Sudarson
  2. According to the specification session beans are not pooled.But this is true if type is stateless session bean . Incase of stateful sessionbean it all depends on the container. If the resources are sufficient in order to process the requests of the clients bean will not be pooled.But if resources are less then stateful session bean will be pooled. Most of the containers follow the LRU(least recently used alogothim). This is specific to the containers. This is true as per as weblogic is concerned. Don't know much about other application servers. Any discussions appreciated.
    raghu
  3. Thanks for the reply. Until now I had the same concept as stated by Richard Monson-Haefel. Just two three days back, some of my friend pointed the stuff in Ed Roman's book. So I would like to request Ed Roman to clarify the stuff, if possible. I think he perhaps meant the same thing, that it's not specified in spec stateful beans pooling, so container may support pooling for SFSB.

    So it would be better, if he clarifies this.

    Regards,
    Sudarson