Session bean concepts

Session beans are non-persistent enterprise beans, in that they do not survive software or hardware crashes, as is the case with entity beans. There are two types of session beans, stateful session beans and stateless session beans.

Session beans may coordinate the work between entity beans, and provide a context for which entity bean access is performed. For example, the task associated with transferring money between two bank accounts—represented by entity beans—can be implemented in a session bean. Such a transfer session bean has to find two instances of the account entity bean (by using the account IDs), and then subtract a specified amount from one account and add the same amount to the other account.

Session bean ...

Get EJB 2.0 Development with WebSphere Studio Application Developer now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.