[Enterprise Extensions only]
  Next topic

WebSphere Enterprise JavaBeans as CORBA clients, the CORBA components

This article describes the main CORBA components for interoperation between enterprise beans running within WebSphere Application Server and CORBA servers running on third-party ORBs and uses a sample application to illustrate the description. The application consists of the following standard components:

The interfaces
The sample application provides two CORBA IDL interfaces. The Primitive interface exercises the primitive CORBA data types, for example, characters, octets, integers, and floats, and the Complex interface exercises the CORBA data types any and Object. The methods in each interface are designed to test the interoperability of that data type. The client sends the server a value; the server modifies the value in a predictable way and returns the value to the client. The client checks the returned value against a locally computed expected value. If they match, then the data type has been successfully transferred between the WebSphere and third-party ORB environments. For more information about the interfaces, see WebSphere Enterprise JavaBeans as CORBA clients, the CORBA interfaces.
The server
The server is a CORBA server running on a third-party ORB. It implements the methods in the two CORBA interfaces in servant objects and makes the servant objects available for clients to use. The implementations are very simple: when the client sends a value, the server modifies it in a predictable way, for example, adding a fixed value to an integer or negating a Boolean, and returns the new value to the client. For more information about the server and its implementation, see Writing CORBA servers for third-party ORBs.
The client
The client using the CORBA servant interfaces is an enterprise bean (a stateless session bean) running in WebSphere Application Server. On the request of its own client, the enterprise bean establishes contact with the CORBA server and invokes methods in one of the CORBA interfaces. Typically, it issues one call to each method and compares the returned results with the expected results. To compute the expected results, the client locally does the same work as the server, using the same code. If the client receives the same value from the server, then the two applications are interoperating properly for the data type being tested. For more information on the server and its implementation, see Writing WebSphere Enterprise JavaBeans that act as CORBA clients .

WebSphere Application Server provides many sample implementations of interoperation with 3rd-party ORBs. These articles use only one representative implementation and discusses the pieces of the client and server relevant to the interoperability issue. It does not discuss the standard parts of the application; for example, the EJB programming model. Writing CORBA servers is discussed in general terms, but the detail is beyond the scope of these articles and the specifics vary with the ORB being used. Although code from a particular implementation is used to illustrate the discussion, it is intended only to help clarify the discussion. It is not expected to work as source code for every ORB.

Additionally, the sample application is used simply as a framework for illustrating the issues surrounding interoperability. The details of the application design and implementation are not discussed. In some cases, the code extracts are distilled from several methods to make clear the logical flow of events rather than to represent the actual call sequence in one specific implementation.

  Next topic