BEA Home | Events | Solutions | Partners | Products | Services | Download | Developer Center | WebSUPPORT
| WebLogic Server Doc Home | WLEC Migration Guide | Previous Topic | Next Topic | Contents | View as PDF

How to Modify WLEC Applications for WebLogic Tuxedo Connector

The following sections provide an information on the steps required to convert your WLEC applications for use with WebLogic Tuxedo Connector:

- How to Modify Your Tuxedo Environment

- How to Modify your WebLogic Server Environment

- How to Modify your WLEC Applications

How to Modify Your Tuxedo Environment

Tuxedo users need to make the following environment changes:

- If an existing Tuxedo application is already using Tuxedo /T DOMAINS, then a new domain must be added to the domains configuration file for each connection to a WebLogic Tuxedo Connector instantiation.

- If the existing Tuxedo application does not use domains, then the domain servers must be added to the TUXCONFIG of the application. A new DMCONFIG must be created with a Tuxedo /T Domain entry corresponding to the WebLogic Tuxedo Connector instantiation.

- WebLogic Tuxedo Connector requires that the Tuxedo domain always have encoding turned on. MTYPE should always be unset or set to NULL in the DMCONFIG file.

- For more information on Tuxedo domains, see the BEA TUXEDO Domains Guide.

- Create a cns server process for the CORBA Name Service.

Note: For more information on Tuxedo domains, see the Overview of the CORBA Name Service.

- Create a C++ proxy server. A Tuxedo C++ Corba server that implements the current ILD interface is required to conver the data types and call WebLogic Server EJB generated IDL interfaces.

How to Modify your WebLogic Server Environment

This section provides information on how to modify your WebLogic Server Environment.

- How to Create an XML Configuration File

- How to Deploy your WebLogic Tuxedo Connector Applications

- How to Create Startup and Shutdown Classes

How to Create an XML Configuration File

Note: For more information on how to create an XML configuration file, see Create a WebLogic Tuxedo Connector XML Configuration File.

This section provides information on how to configure your XML configuration file to support a call to a Tuxedo CORBA server from a WebLogic Server EJB. Use the following steps to modify the BDMCONFIG section of your XML configuration file:

1. Configure a T_DM_LOCAL_TDOMAIN section for your WebLogic Server domain.

2. Configure a T_DM_REMOTE_TDOMAIN section for your Tuxedo CORBA domain.

3. Configure a T_DM_IMPORT section.

   - Set ResourceName to "//domain_id" where domain_id is DOMAINID specified in the Tuxedo UBBCONFIG file. The maximum length of this unique identifier for CORBA domains is 15 characters and includes the //.

   - Set LocalAccessPoint to the value of the LocalAccessPoint element of the T_DM_REMOTE_TDOMAIN.

   - RemoteAccessPointList to the value of the AccessPointId element of the T_DM_REMOTE_TDOMAIN.

   - Optional. Specify the transaction timeout value.

How to Configure Connections Between Domains

WebLogic Tuxedo Connector uses the Tuxedo /T Domain gateway to create a single network link between a WebLogic Server instance and a Tuxedo domain for all method invocations.

Use the ConnectionPolicy parameter in the T_DM_LOCAL_TDOMAIN and T_DM_REMOTE_TDOMAIN sections of BDMCONFIG to configure connections between domains. You can select ON_DEMAND, ON_STARTUP, INCOMING_ONLY, and LOCAL. For more information, see Configuring the Connections Between Domains.

How to Configure for Failover

To support failover, you must specify the remote domains responsible for executing a particular service. Specifically, you must specify each remote domain with a T_DM_REMOTE_TDOMAIN section in your XML configuration file. For more information, see Configuring Domains-level Failover and Failback .

How to Configure Authentication of Remote Domains

Domain gateways can be made to authenticate incoming connections requested by remote domains and outgoing connections requested by local domains. You can specify the level of security used by a particular local domain by setting the SECURITY parameter in the T_DM_LOCAL_TDOMAIN section of your XML configuration file. There are three levels of password security: NONE, APP_PW, DM_PW. For more information see, Authentication of Remote Domains.

How to Configure Access Control Lists

Access Control Lists (ACLs) limit the access to local services within a local domain by restricting the remote domains that can execute these services. Inbound policy from a remote domain is specified using the AclPolicy element. Outbound policy towards a remote domain is specified using the CredentialPolicy element. This allows WebLogic Server and Tuxedo applications to share the same set of users and the users are able to propagate their credentials from one system to the other. For more information, see How to Configure WebLogic Tuxedo Connector to Provide Security between Tuxedo and WebLogic Server.

How to Configure Link-Level Encryption

You can use encryption across domains to ensure data privacy. Configure this security mechanism by setting the MINENCRYPTBITS and MAXENCRYPTBITS parameters of the T_DM_LOCAL_TDOMAIN and the T_DM_REMOTE_TDOMAIN sections of your XML configuration file. For more information, see Link-Level Encryption.

How to Deploy your WebLogic Tuxedo Connector Applications

The following sections provide information on how to migrate your WLEC weblogic-ejb-jar.xml file and the build.xml file for use with WebLogic Tuxedo Connector.

- How to Update Your weblogic-ejb-jar.xml File

- How to Update Your build.xml File

- How to Generate a WebLogic Server EJB IDL Interface

How to Update Your weblogic-ejb-jar.xml File

This section will provide information on how to update your weblogic-ejb-jar.xml .file.

- remove the connection pool stuff

- add the proper stuff back in

How to Update Your build.xml File

This section will provide information on how to update your build.xml file.

- what ever the steps are

How to Generate a WebLogic Server EJB IDL Interface

Use the weblogic.ejbc utility to extract the IDL interface from the WebLogic Server EJB interface.

- what ever the steps are

How to Create Startup and Shutdown Classes

In order to use the WebLogic Tuxedo Connector, you must create a WebLogic Server Startup and Shutdown class. For more information see, Create a StartUp Class for the WebLogic Tuxedo Connector and Create a Shutdown Class for the WebLogic Tuxedo Connector .

How to Modify your WLEC Applications

This section provides information on how to modify WLEC applications to interoperate with WebLogic Server and Tuxedo CORBA objects using WebLogic Tuxedo Connector.

- How to Modify Your WLEC EJB to Reference CORBA Objects Used by WebLogic Tuxedo Connector

- How to Modify WLEC Transactions for WebLogic Tuxedo Connector

How to Modify Your WLEC EJB to Reference CORBA Objects Used by WebLogic Tuxedo Connector

Use the following steps to modify your EJB to use WebLogic Tuxedo Connector to invoke on CORBA objects deployed in Tuxedo:

- Remove References to Tobj_Bootstrap Object

- Remove References to the FactoryFinder Object

- How to Initialize the WTC ORB

- How to Get the Simple Factory

- How to Get the Simple Object

- How to Invoke on the Simple Object

Remove References to Tobj_Bootstrap Object

Each WLEC connection pool has a Tobj_Bootstrap object used to access the Tuxedo domain. Example:

>     Tobj_Bootstrap myBootstrap =
>     Tobj_BootstrapFactory.getClientContext("myPool");

where

- The getClientContext() method returns the Tobj_Bootstrap object associated with mypool.

- myPool is the name of the WLEC connection pool for the desired BEA Tuxedo domain.

Remove references to the Tobj_Bootstrap object. WebLogic Tuxedo Connector uses the XML configuration file to provide information required to create a path to the Tuxedo service. This pathway is created when the WebLogic Server is started and the WebLogic Tuxedo Connector XML configuration file is loaded.

Remove References to the FactoryFinder Object

Remove references to the FactoryFinder object. This object is obtained using the Tobj_Bootstrap object.

>     org.omg.CORBA.Object myFFObject =
>         myBootstrap.resolve_initial_references("FactoryFinder");
>     FactoryFinder myFactFinder =
>         FactoryFinderHelper.narrow(myFFObject);

where

- myBootstrap is the Tobj_Bootstrap object for the desired BEA Tuxedo domain.

- The resolve_initial_references() method returns the object reference for the FactoryFinder object.

- The FactoryFinderHelper interface provides auxiliary functionality for the FactoryFinder interface, notably the narrow() method.

- The narrow() method casts the object reference to point to a FactoryFinder object.

How to Initialize the WTC ORB

To use CORBA with the WebLogic Tuxedo Connector, you must use the WTC ORB. WLEC uses the weblogic.jndi.WLInitialContextFactory to return a context used by the Tobj_Bootstrap object. Replace the WLEC context reference and instantiate the WTC ORB in your Bean. Example:

>     // Initialize the ORB.
>     String args[] = null;
>     Properties Prop;
>     Prop = new Properties();
>     Prop.put("org.omg.CORBA.ORBClass", "weblogic.wtc.corba.ORB");
>     ORB orb = ORB.init(args, Prop);

How to Get the Simple Factory

The WebLogic Tuxedo Connector uses the CosNaming service to get a reference to an object in the remote Tuxedo CORBA domain. This is accomplished by using a corbaloc:tgiop or corbaname:tgiop object reference. Example:

>     // Get the simple factory.
>     org.omg.CORBA.Object simple_fact_oref =
>     orb.string_to_object("corbaname:tgiop:simpapp#simple_factory");

>     // Narrow the simple factory.
>     SimpleFactory simple_factory_ref =
>     SimpleFactoryHelper.narrow(simple_fact_oref);

Where:

- simpapp is the domain id of the Tuxedo domain specified in the Tuxedo UBB.

- simple_factory is the name that the object reference was bound to in the CosNaming server in Tuxedo CORBA..

- The SimpleFactoryHelper interface provides auxiliary functionality for the interface, notably the narrow() method.

- The narrow() method casts the object reference to point to the object factory.

How to Get the Simple Object

Get the BEA Tuxedo CORBA object using the object's find() method. For example, if you are accessing an object named Simple, use the following code:

>     // Find the simple object.
>     Simple simple = simple_factory_ref.find_simple();

where the factory provides the find_simple() method for finding the Simple object.

For information about the FactoryFinder object, see the CORBA C++ Programming Reference in the BEA Tuxedo documentation.

How to Invoke on the Simple Object

Perform your task by invoking upon the CORBA object deployed in Tuxedo using the CORBA Java API.

>     // Invoke the to_upper opeation on Simple object
>     org.omg.CORBA.StringHolder buf =
>               new org.omg.CORBA.StringHolder(mixed);
>     simple.to_upper(buf);
>     result = buf.value;

How to Modify WLEC Transactions for WebLogic Tuxedo Connector

The following sections provide information on how to modify WLEC applications that use transactions to interoperate with Tuxedo using WebLogic Tuxedo Connector.

- Peter Bower's information goes here

Copyright © 2001 BEA Systems, Inc. All rights reserved. Required browser: Netscape 4.0 or higher, or Microsoft Internet Explorer 4.0 or higher.