We have now completed our examination of entity beans. This chapter presented an employee Benefits Enrollment application that was similar to the example presented earlier. However, this example was built and deployed using entity beans when appropriate rather than relying completely on session beans. The example application clearly illustrated the differences, from a developer's point of view, of using entity beans. The application focused on the various techniques for working with entity beans, such as using container-managed persistence and container-managed relationships, caching persistent state, subclassing techniques, and so forth, and how best to use the features of these types of beans. The example application also illustrated how to use the EJB timer service and the JavaMail APIs to provide plan administrators with statistics about the application by e-mail on a regular basis. This chapter showed how entity beans are more appropriate for applications that must be easily adapted for different customers with different operational environments. Typically, these are applications built by ISVs rather than by an enterprise's in-house IT department. |