Deploying EJB modules

When you deploy an Enterprise JavaBeans (EJB) module, you install that module on a server that has been configured to support deployed modules.

Before you begin

Assemble one or more EJB modules, assemble one or more web modules, and assemble them into a Java™ EE application.

For an overview about the changes to the EJB deployment model for EJB 3.x, see the topic EJB 3.x deployment overview.

Procedure

  1. Prepare the deployment environment.
    See the topic Preparing to host applications.
  2. Update the configuration for each EJB module as needed for the deployment environment.
  3. Required: If a module has dependencies on Java 5-specific extensions, such as generics, annotations, and so on, then you must specify the -complianceLevel 5.0 option (deployejb.complianceLevel 5.0, if using wsadmin) when you invoke the EJBDeploy tool.

    It is only necessary to run the EJBDeploy tool for EJB modules containing entity beans.

  4. Deploy the application.
    See the topic Deploying and administering enterprise applications.

What to do next

If you specify that the EJBDeploy tool be run during application installation and the installation fails with a NameNotFoundException message, ensure that the input Java archive (JAR) or enterprise archive (EAR) file does not contain source files. Either remove the source files or include all dependent classes and resource files on the class path. If there are source files in the input JAR or EAR file, the EJB deployment tools runs a rebuild before generating the deployment code.

If the module deploys successfully, test and debug the module. See the topic Diagnosing problems (using diagnosis tools).