O'Reilly logo

Sams Teach Yourself EJB in 21 Days by Krishna Kothapalli, Ragae Ghaly

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Developing JavaMail Applications

Today you'll develop the Emailer EJB, which is responsible in our university registration system for sending e-mails to students when they submit courses at enrollment time, and for notifying them again when they are approved for registration.

Our example today uses the Model-View-Controller (MVC) architecture pattern to design a JavaMail application. The servlet component in the Web tier represents the controller, which acts as a client to the EJB tier. The Emailer EJB in the EJB tier represents the model, which handles business logic (primarily sending an e-mail message). The view is represented by an HTML form (which could be a JSP) that interacts with the servlet. Figure 20.2 illustrates the use of the MVC ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required