Packaging EJBs

EJBs and their deployment descriptor are passed between the EJB roles and eventually deployed using an ejb-jar file. This JAR file contains

  • The home and component interfaces

  • The bean implementation classes

  • Any custom primary key classes

  • All dependent classes and interfaces

  • The ejb-jar.xml deployment descriptor (stored in a META-INF subdirectory relative to the root of the JAR)

  • Any vendor-specific deployment descriptors

As a bean provider, you can create an ejb-jar file by following these steps:

1.
Compile your EJBs and their supporting classes and interfaces
2.
Define the required parts of the deployment descriptor(s) and copy these files to a META-INF directory that’s parallel to the root directory of your package hierarchy. For ...

Get Special Edition Using Enterprise JavaBeans™ 2.0 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.