EJB deployment tool

Before you can successfully run your enterprise beans on either a test or production server, you need to generate deployment code for the enterprise beans. The EJB deployment tool provides a command-line interface that you can use to generate enterprise bean deployment code. The tool employs this command-line environment that enables you to run a build process overnight and have the deployment tool automatically invoked to generate your deployment code in batch mode.

The EJB deployment tool is invoked from the command line using the ejbdeploy command, which accepts an input EJB JAR or EAR file that contains one or more enterprise beans. It then generates an output, deployed JAR file or EAR file that contains deployment code in the form of .class files.

For a complete description of all of the options available to the ejbdeploy, see the related reference The ejbdeploy command.

The EJB deployment tool supports EJB single and multiple table inheritance. It supports the use of converters, which translate a database representation to a Java™ object type, and composers, which are used to map a single, complex bean field to multiple database columns. The EJB deployment tool supports the following levels of access intent (where AccessIntent is a WebSphere® extension):

  1. wsPessimisticUpdateWeakestLockAtLoad
  2. wsPessimisticUpdate
  3. wsPessimisticUpdate-NoCollision
  4. wsPessimisticUpdate-Exclusive
  5. wsPessimisticRead
  6. wsOptimisticUpdate
  7. wsOptimisticRead

For more information on these access intents, see the related topic Access intent and isolation level.

In addition to these values, an access intent can also contain an optional read ahead hint.

Note: The read ahead hint indicates how deeply to read ahead in an EJB relationship graph.
2.0 EJB projects only: Mapping to multiple back-end databases is also supported. The schemas and the generated data definition language (DDL) file are stored in the following directory of the JAR or EAR file:

META-INF\backends\backend_id\databasename.dbm

META-INF\backends\backend_id\Table.ddl

If multiple backends exist and you did not set the current back-end ID in the EJB deployment descriptor, the EJB deployment tool will default to the first back-end ID that appears as a folder in the respective META-INF\backends directory as described earlier. If you map to a single backend database, then the generated DDL file will appear both in the directory as described above and also in the META-INF folder.

You can perform the following tasks with the EJB deployment tool:

Also refer to Message format for EJB validation to understand the format used for messages generated by the EJB validator.

Related reference
The ejbdeploy command