Day 10. Message-Driven Beans
So far, you have looked at two types of Enterprise Java Bean (EJB)—the Session bean and the Entity bean. Today you will consider the third and final EJB, the Message-driven bean. Topics that are covered are as follows:
Similarities and differences with Entity and Session beans
The life-cycle of a Message-driven bean
Writing a Message-driven bean
Prior to the EJB 2.0 specification, it was only possible to support asynchronous message passing by writing an external Java program that acted as a listener. A listener is a program whose sole purpose is to wait for data to arrive, for example, a socket server program that “listens” on a socket and perform some action when it detects client connections. The listener was then ...
Get Sams Teach Yourself J2EE™ in 21 Days now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.