Java Tutorial - Java Scipt : Stateless Beans

Java Tutorial - Java Scipt :

Stateless Beans


Stateless session beans are EJBs that have neither state nor persistence characteristics. By foregoing those characteristics, stateless session beans gain increased scalability. These are great for handling requests that can be completed within a single request. Because they are stateless, an EJB container can create or destroy stateless
session beans as necessary, to match the processing load. They are interchangeable and can be easily distributed to many nodes within a clustered application server. Stateless session beans can perform most tasks. They often act as facades that coordinate the activity of many other components, such as other EJBs, for a client. Another great use pattern is to have them front a distributed persistence mechanism such as JDO or Hibernate, thus gaining the benefits of container management without having to deal with heavy component-oriented persistence schemes such as container-managed beans.