First page Back Continue Last page Graphics

Session Beans...


Notes:

Stateful session beans are removed by the client. The client does so by calling the remove( ) method of the EJBObject interface.
Session beans can be “removed”. For stateless session beans, removal occurs when the container decides to release the instance in order to shrink the pool. It is never called in response to client action. Clients do not remove stateless session beans.
Note that a client can (and often will) call that same remove( ) method against a stateless session bean. This is how the client severs the connection and ends the session. However, it does not “remove” the bean in the sense of destroying the bean instance. Only the container can do that, and it does so only when it wants to shrink the pool.