Deploying EJB applications to managed Liberty targets
You can install Jakarta Enterprise Beans (EJB) version 4.0 applications or modules on managed Liberty servers and managed Liberty clusters with the administrative console or wsadmin scripting.
Before you install an EJB application, configure the target managed Liberty server or managed Liberty cluster. As part of the configuration, determine whether your EJB application files can be installed to your deployment target.
Enterprise bean modules installable on managed Liberty servers and managed Liberty clusters
You can install enterprise bean applications on managed Liberty servers and managed Liberty clusters that are written to the following Jakarta Enterprise Beans 4.0 API groups.
- EJB Lite
The enterpriseBeansLite-4.0 feature supports the EJB Lite API group.
- EJB 2.x
The enterpriseBeansHome-4.0 feature supports the EJB 2.x API group.
- EJB Remote
The enterpriseBeansRemote-4.0 feature supports the EJB Remote API group.
Install files that use Jakarta EE 10 specifications and a supported Java™ SE version on a managed Liberty server or a managed Liberty cluster.
Installing EJB applications on managed Liberty servers and managed Liberty clusters
- Installing applications on managed Liberty servers and managed Liberty clusters with the consoleAs you go through the installation steps, you get to a step where you install your EJB application files and select installation options.
- Select the Allow EJB reference targets to resolve automatically option to
install the EJB application without specifying bindings for EJB references.
If only one bean implements the referenced EJB interface, the application server automatically resolves bindings for EJBs that are located in the same application.
- The Deploy enterprise beans option is not available for EJB applications that are targeted to a managed Liberty server or managed Liberty cluster. However, the application server generates the required EJB artifact automatically.
- Select the Allow EJB reference targets to resolve automatically option to
install the EJB application without specifying bindings for EJB references.
- Installing applications on managed Liberty servers and managed Liberty clusters with wsadmin scriptingAs you go through the installation steps, you get to a step where you install your EJB application files and select installation options.
- Select the useAutoLink option to install the EJB application without
specifying bindings for EJB references.
If only one bean implements the referenced EJB interface, the application server automatically resolves bindings for EJBs that are located in the same application.
- The deployejb option is not available for EJB applications that are targeted to a managed Liberty server or managed Liberty cluster. However, the application server generates the required EJB artifact automatically.
- Select the useAutoLink option to install the EJB application without
specifying bindings for EJB references.
You can use the ibm-ejb-jar-bnd.xml and ibm-ejb-jar-ext.xml files to include bindings and extensions for EJB 4.0 modules in the application. These files use the same format as EJB 3.x modules. For more information, see EJB 3.0 and EJB 3.1 application bindings overview.
Extra considerations for developing EJB 4.0 applications for managed Liberty servers and managed Liberty clusters
- The Jakarta Enterprise Beans 4.0 specification did not introduce any new features; only the API
package namespace was changed from
javaxtojakarta. Therefore, most of the documentation for developing an EJB 3.x application is also applicable to Jakarta Enterprise Beans 4.0 applications. For more information, see Developing EJB 3.x enterprise beans. - Managed Liberty servers and managed Liberty clusters do not support a distributed naming
context. Qualified names, topology-based names, and fixed names are not available for looking up EJBs.
- EJBs in the same server process can be looked up in JNDI with either the
java:name or the name that is bound to the server context root. - EJBs with remote interfaces can be looked up in JNDI from a separate server process by using a corbaname URL that follows standard Liberty syntax. For more information, see Using enterprise JavaBeans with remote interfaces on Liberty.
- EJBs in the same server process can be looked up in JNDI with either the
- For limitation information about deploying EJB applications, see the Application scanning and deployment section of the limitations topic.