Architectural overview: Message-driven beans

Message-driven beans don’t have a client view. That means they don’t have interfaces (Remote or local) that expose methods to the client. In other words, message-driven beans don’t have a Home or EJBObject. They don’t have a Home interface or a Component interface.

image with no caption
  1. The client sends a message to a JMS messaging service.

  2. The messaging service delivers the message to the container.

  3. The container gets a message-driven bean out of the pool.

  4. The container delivers the message to the bean (by calling the bean’s onMessage() MessageListener interface method).

Get Head First EJB 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.