[Enterprise Extensions only]

WebSphere EJB server (as a CORBA client) to CORBA server

Enterprise JavaBeans are Java objects operating in a sophisticated runtime environment (EJB containers). The EJB container manages transactions, security, and other services. These typically correspond to CORBA services. Because EJBs are Java objects they can act as CORBA clients, using the CORBA ORB managed by the container, as shown in the following figure. Enterprise JavaBeans, acting as CORBA clients using the WebSphere Java ORB, benefit from full propagation of service contexts because of the tight integration between the EJB container and the ORB.


WebSphere EJB server (as a CORBA client) to CORBA server scenario

WebSphere EJB server (as a CORBA client) to CORBA server scenario. This figure shows a WebSphere EJB server, as a CORBA client, accessing server implementation objects hosted by a CORBA server. For more information, see the text following the figure.

In this scenario, when the client (an Enterprise JavaBean on a WebSphere EJB server) wants to call a method on a servant object, the following sequence of events occur:

  1. When the client environment is started, the client ORB is initialized and the ORB bootstrap process gets access to the naming service (with CORBA CosNaming bindings).
  2. When an Enterprise JavaBean needs to access a CORBA servant object, the WebSphere EJB server uses the naming service to find the servant object then return the interoperable object reference (IOR) of the servant back to the client.
  3. The client creates a stub object (local to the client) for the servant and stores the IOR in the stub object.
  4. The client uses the IOR to locate the servant and the stub object to communicate with the servant as though it was a local process.

For more information about the elements in this scenario, see An overview of basic CORBA concepts.