Developing a CORBA C++ server

Why and when to perform this task

Use this task to develop a CORBA server to service requests for business functions used in the implementation of client objects. The instructions and code extracts provided in this task are based on the development of the WSLoggerServer sample and are accessible from the Samples Gallery. The Samples Gallery is installed with WebSphere Application Server.

Steps for this task

  1. Create and edit an IDL file, servant.idl, to specify the public interface to the servant object class; where servant is the name of the server implementation class.
    For more information about creating and editing an IDL file for the servant object class, see Defining the interface for a CORBA servant class.
    This step results in a fully specified servant.idl file.
  2. Compile the servant IDL file, servant.idl, to produce the usage binding files needed to implement and use the servant object within a particular programming language.
    For more information about compiling an IDL file, see Compiling a CORBA server implementation class IDL (using idlc).
    This step results in the set of usage binding files required for the servant.idl file.
  3. Add declarations for class variables, constructors, and destructors to the servant implementation header (servant.ih).
    For more information about adding declarations to an implementation header, see Adding declarations to a CORBA servant implementation header (servant.ih).
    This step results in the servant implementation header file, servant.idl, that contains all the declarations for class variables, constructors, and destructors needed by the implementation.
  4. Complete the servant implementation servant_I.cpp, to add the code that implements the servant business logic.
    For more information about completing the servant implementation, see Adding code to a CORBA servant implementation (servant_I.cpp).
    This step results in the server implementation file, servant_I.cpp, that contains the code needed by the implementation to support the business logic.
  5. Create the server main source file, server.cpp, to write the code for the methods that the server implements. (For example, to perform initialization tasks and create servant objects).
    For more information about completing the servant implementation, see Creating the server main code (server.cpp).
    This step results in the server main source file, servant.cpp, that contains the main() function and associated code needed to implement the server.
  6. Build the server code as described in Building a CORBA C++ server.
  7. Store a logical definition for the server in the system implementation repository (using regimpl).
    For more information about storing a logical definition in the implementation repository, see Storing a logical definition for a CORBA server in the system implementation repository.
    This step results in the implementation repository containing an entry for the server and the server object implementation class that it supports.

Related tasks
Implementing CORBA applications



Searchable topic ID:   tcor_pgms0
Last updated: Jun 21, 2007 8:07:48 PM CDT    WebSphere Business Integration Server Foundation, Version 5.0.2
http://publib.boulder.ibm.com/infocenter/wasinfo/index.jsp?topic=/com.ibm.wasee.doc/info/ee/corba/tasks/tcor_pgms0.html

Library | Support | Terms of Use | Feedback