Accessing Mainframe from Java

     Previous  Next    Open TOC in new window    View as PDF - New Window  Get Adobe Reader - New Window
Content starts here

Tuxedo Mainframe Transaction Publisher

This document includes the following topics:

 


Overview

Tuxedo Mainframe Transaction Publisher simplifies the process of exposing mainframe transaction in Oracle Service Bus (OSB) by providing a graphical user interface.

Let us consider this scenario, where users want to expose their mainframe transaction in OSB. The proxy service uses WSDL and the business service uses WTC.

The tool generates POJO code based on the input COBOL copybook. These generated codes can be used by users to access mainframe transaction.

 


Using Tuxedo Mainframe Transaction Publisher

Tuxedo Mainframe Transaction Publisher includes two parts: Generator and Publisher. They are implemented as JDeveloper extensions and reside in a single JAR file.

Tuxedo Mainframe Transaction Publisher is a project based tool. Users select the project and right click to bring up context menu.

Note: Users install this extension using JDeveloper's update center mechanism. For more information, see Installing Tuxedo Mainframe Transaction Publisher.

Tuxedo Mainframe Transaction Generator

Tuxedo Mainframe Transaction Generator is implemented through the JDeveloper hook. Users access this function by clicking the "Tuxedo Mainframe Transaction Generator" menu item.

By selecting this function, a graphical user interface base wizard window will be brought up to guide users to do the following things.

  1. Select COBOL Copybook
  2. Define Code Generation Details
  3. Configure Transaction Input and Output
  4. Enter Transaction Details

Eventually, Tuxedo Mainframe Transaction Generator generates seven artifacts that are organized in two parts.

Select COBOL Copybook

The following picture shows the wizard page for selecting COBOL copybook.

Define Code Generation Details

The following screenshot shows the wizard page for defining code generation details.

The following fields are used.

Transaction ID

Name of the mainframe transaction. This is used in code and artifacts generation to name the OSB project, artifacts, and data mapping classes.

POJOs Package

This is used as Java package name for the mapping classes.

Namespace

This is used as WSDL and schema namespace in the WSDL and XSD OSB artifacts.



Configure Transaction Input and Output

The following screenshot shows the wizard page for configuring the input and output fields from the COBOL copybook.

Enter Transaction Details

The following screenshot shows wizard page for entering information needed by mainframe transaction.

The following fields are used.

Tuxedo transaction resource name

Name of the generated Tuxedo transport/WTC import that will be generated.

Tuxedo transaction remote name

Name of the Tuxedo service on the remote Tuxedo domain as exported from there.

Tuxedo remote domain

ID of the remote Tuxedo/TMA domain.

Tuxedo network address

Network address for the Tuxedo/TMA remote domain.

OSB local domain

ID of the OSB domain.

OSB network address

Network address of the OSB domain.

WebLogic target server

Name of the WLS server.



Users are allowed to set the defaults value for the mainframe transaction details according to user needs through the JDeveloper's "Preference" menu item from the "Tools" drop down menu.

Tuxedo Mainframe Transaction Publisher

Tuxedo Mainframe Transaction Publisher is implemented through the UI hook. Users access this function by selecting the Tuxedo Mainframe Transaction Publisher menu item.

By selecting this function, a welcome wizard page will be displayed to do the following things.

  1. Pack Artifacts
  2. Publish to OSB

Pack Artifacts

In this step, the artifacts generated by Tuxedo Mainframe Transaction Generator are packed. The following wizard page tells users the name of the packaged JAR file, and where it will be generated.

Publish to OSB

The following wizard page helps users to publish the generated artifacts to OSB. This Tuxedo Mainframe Transaction Publisher function allows users to specify the OSBs URL, administrator's name, and administrator's password.

Note: Tuxedo Mainframe Transaction Publisher allows users to manually install the OSB project by not selecting "Publish to Oracle Service Bus (OSB)?".

 


Installing/Uninstalling Tuxedo Mainframe Transaction Publisher

Prerequisite

To ensure successful installation of the Tuxedo Mainframe Transaction Publisher, a pristine JDeveloper should be used. Users should install the pristine JDeveloper at a new location; they should neither import any preference from other installations nor use JDeveloper to start from installer.

After installation, users use the following commands to start the JDeveloper.

Note: JDeveloper Studio is available for download from Oracle Technology Network.

Installing Tuxedo Mainframe Transaction Publisher

The Tuxedo Mainframe Transaction Publisher is distributed in a single zip file named "tuxedo.mtp.update.<version>.zip". Its current version is 12.1.2.0.

Do the following steps to complete the Tuxedo Mainframe Transaction Publisher installation.

  1. Select "Install From Local File" and enter the zip file location in "File Name:" text field.
  2. Click the "Next" button (and the "Summary" page shows up).
  3. Click the "Finish" button to complete the installation.

After completing the installation, jar files will be installed in MW_HOME/JDeveloper/jdev/extension/tuxedo directory.

Note: The zip file is located in $TUXDIR/udataobj. To find out "tuxedo.mtp.update.12.1.2.0.zip", open the JDeveloper and click the "Help" menu item in the menu bar, and select "Check for Updates" from the drop down menu that is brought up.

Checking Installation Status

After the installation, when the updater asks to restart JDeveloper, choose not to. Then users go to the command line and re-enter jdeveloper/jdev/bin/jdev -clean -console to verify whether the installation is successful.

Users can check the installation status using any of the following ways.

Using graphical user interface

Click "Help"- "About" - "Extension".

Using command lines

Listing 1 Using Command Lines to Check Installation Status
D:\oracle\jdeveloper\12.1.2_2>jdeveloper\jdev\bin\jdev -su -clean -console
osgi>
osgi> ss tuxedo
Framework is launched.
id      State       Bundle
927     RESOLVED    com.oracle.tuxedo.mtp_12.1.2

Uninstalling Tuxedo Mainframe Transaction Publisher

Do the following steps to uninstall the Tuxedo Mainframe Transaction Publisher from JDeveloper's menu bar.

  1. Click the "Tools" menu item (and a drop down menu shows up).
  2. Select the "Features" (and the "Manage Features and Updates" page shows up.
  3. Select the "Installed Updates".
  4. Select "Tuxedo MF Transaction Publisher".
  5. Click "Uninstall" button to complete the uninstallation.


Installation Notes

Tuxedo Mainframe Transaction Publisher requires

Note: When users install Tuxedo Mainframe Transaction Publisher on Oracle JDeveloper 12.1.2 extension, a matisse related exception will be reported. This exception has no impact on the use of Tuxedo Mainframe Transaction Publisher.

 


Setting up JDeveloper Project

Users must set up the "Library and Classpath" for every project before using Tuxedo Mainframe Transaction Publisher; otherwise, the compilation of the generated class fails.

To do the setup, right click the project to bring up context menu and select "Project Properties". Then select "Add JAR/Directory" and add the eGen libraries.

 


Setting up Oracle Service Bus (OSB)

Installing EGen Libraries for OSB

It is required for users to add eGen libraries to OSB's classpath by doing the following steps.

  1. Create or use an existing Oracle Service Bus Domain.
  2. Edit <domain_path>/bin/setDomainEnv.sh and eGen libraries to the classpath.
  3. Restart OSB to reflect these changes in the classpath.

The eGen libraries can be extracted from the updated zip file.

Users should add the followings to setDomainEnv.sh.

Listing 2 Adding Information to setDomainEnv.sh
#
# EGen Classpath for MTP
#
BASE_EGEN_LIBS_PATH=<location of the libraries>
EGEN_CLASSPATH=${BASE_EGEN_LIBS_PATH}/com.bea.core.xml.xmlbeans_2.2.0.0.jar${CLASSPATHSEP}${BASE_EGEN_LIBS_PATH}/weblogic_apache.jar${CLASSPATHSEP}${BASE_EGEN_LIBS_PATH}/xmltoolkit.jar${CLASSPATHSEP}${BASE_EGEN_LIBS_PATH}/egen.jar
CLASSPATH="${CLASSPATH}${CLASSPATHSEP}${EGEN_CLASSPATH}"
export CLASSPATH

Importing Shared Resources to OSB

An OSB project with some shared resources is used by Tuxedo Mainframe Transaction Publisher generated OSB resources. The file with complete OSB project is in $TUXDIR/udataobj/mtp_shared_sbconfig.jar.

  1. Use OSB's console to import this JAR.
  2. System Administration > Import Resources



  3. Enter the mtp_shared_sbconfig.jar location.


  4. Click "Next>>" button.


  5. Select "Import".


  6. Click "Activate" button.
  7. Click "Submit" button.
  8. Check for any error or conflict and resolve them.

  Back to Top       Previous  Next