Chapter 13. Packaging EJB 3 applications

 

This chapter covers

  • The Java EE module system
  • Class loading in EE applications
  • Packaging EJBs and MDBx
  • Packaging JPA
  • Packaging CDI

In the previous chapters you learned how to build a business logic tier with session and message-driven beans, and you used entities to support the persistence tier. But now that you have all this code, what do you do with it?

This chapter begins with a discussion of application packaging and deployment—the fundamentals needed to get your Enterprise application running. We’ll explore how the various modules (JAR, EJB-JAR, WAR, CDI, and EAR) of an EE application fit together and interact when deployed to the EE server. We’ll discuss how EE applications are configured both through annotations and XML. Finally, we’ll cover best practices and some common deployment issues, especially when deploying the same application across different EE server implementations. Let’s start by looking at the EE modules and how they’re packaged together.

13.1. Packaging your applications

13.2. Exploring class loading

13.3. Packaging session and message-driven beans

13.4. JPA packaging

13.5. CDI packaging

13.6. Best practices and common deployment issues

13.7. Summary