Skip Headers
Oracle Procedural Gateway® for APPC Installation and Configuration Guide
10g Release 2 (10.2) for Microsoft Windows

Part Number B16211-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Feedback

Go to previous page
Previous
Go to next page
Next
View PDF

1 Introduction to Oracle Procedural Gateway for APPC

The Oracle Procedural Gateway for APPC (the "gateway") enables users to initiate transaction program execution on remote online transaction processors (OLTPs.) The Oracle Procedural Gateway for APPC can establish connection with OLTP using the SNA communication protocol. The gateway can also use TCP/IP for IMS Connect to establish communication with the OLTP through TCP/IP. The gateway provides Oracle applications with seamless access to IBM mainframe data and services through Remote Procedural Call (RPC) processing. The gateway can access any application capable of using the CPI-C API either directly or through a TP monitor such as CICS.

This chapter discusses the architecture, uses, and features of the gateway. It contains the following sections:

1.1 Overview of the Gateway

The Oracle Procedural Gateway for APPC extends the Remote Procedural Call (RPC) facilities available with the Oracle server. The gateway enables any client application to use PL/SQL to request execution of a remote transaction program (RTP) residing on a host. The gateway provides RPC processing to systems using the SNA APPC (Advanced Program-to-Program Communication) protocol and to systems using TCP/IP for IMS Connect protocol. This architecture allows efficient access to data and transactions available on the IBM mainframe and IMS, respectively.

The gateway requires no Oracle software on the remote host system. Thus, the gateway uses existing transactions with little or no programming effort on the remote host.

For gateways using SNA:

The use of a generic and standard protocol, APPC, allows the gateway to access a multitude of systems. The gateway can communicate with virtually any APPC-enabled system, including IBM Corporation's CICS on any platform, IBM Corporation's IMS and APPC/MVS, and Computer Associates' IDMS. These transaction monitors provide access to a broad range of systems, allowing the gateway to access many datastores, including VSAM, DB2 (static SQL), IMS, IDMS, ADABAS, and others.

The gateway can access any application capable of using the CPI-C API either directly or through a TP monitor such as CICS.

1.2 Features of the Gateway

The Oracle Procedural Gateway for APPC provides the following benefits:

1.3 Terms

The following terms and definitions are used throughout this guide. Refer to Appendix C, "Gateway Terminology" for a more elaborate list of terms and definitions pertaining to the gateway, its components and functions.

Oracle Integrating Server

This is any Oracle server instance that communicates with the gateway for purposes of performing remote procedural calls to execute remote transaction programs (RTP). The Oracle Integrating Server can be on the same system as the gateway or on a different system. If it is on a different system, then Oracle Net is required on both systems. Refer to Figure 1-2, "Gateway Architecture" for a view of the gateway architecture.

OLTP

Online Transaction Processor (OLTP) is any of a number of online transaction processors available from other vendors, including CICS Transaction Server for z/OS, IMS/TM, z/OS and IDMS-DC.

PGAU

Procedural Gateway Administration Utility (PGAU) is the tool that is used to define and generate PL/SQL transaction interface packages (TIPs.) Refer to Chapter 2, "Procedural Gateway Administration Utility" in the Oracle Procedural Gateway for APPC User's Guide for Microsoft Windows for more information about PGAU.

PG DD

Procedural Gateway Data Dictionary (PG DD) is a repository of remote host transaction (RHT) definitions and data definitions. PGAU accesses definitions in the Data Dictionary (PG DD) when generating TIPs. The PG DD has datatype dependencies because it supports the PGAU and is not intended to be directly accessed by the customer. Refer to Appendix A, "Procedural Gateway for APPC Data Dictionary" in the Oracle Procedural Gateway for APPC User's Guide for Microsoft Windows for a list of PG DD tables.

RPC

Remote Procedural Call (RPC) is a programming call that executes program logic on one system in response to a request from another system. Refer to "Gateway Term Definitions" for more information, and refer to Appendix C, "Gateway RPC Interface" in the Oracle Procedural Gateway for APPC User's Guide for Microsoft Windows as well.

RTP

A remote transaction program (RTP) is a customer-written transaction, running under the control of an OLTP, which the user invokes remotely using a PL/SQL procedure. To execute a RTP through the gateway, you must use RPC to execute a PL/SQL program to call the gateway functions.

TIP

A Transaction Interface Package (TIP) is an Oracle PL/SQL package that exists between your application and the remote transaction program. It is a set of PL/SQL stored procedures that invoke the remote transaction program through the gateway. TIPs perform the conversion and reformatting of remote host data using PL/SQL and UTL_RAW or UTL_PG functions.

Figure 1-1, "Relationship of Gateway and Oracle Integrating Server on Windows" illustrates where the terminology discussed in the preceding sections apply within the gateway's architecture.

Figure 1-1 Relationship of Gateway and Oracle Integrating Server on Windows

Description of Figure 1-1 follows
Description of "Figure 1-1 Relationship of Gateway and Oracle Integrating Server on Windows"

1.4 Architecture of the Gateway

The architecture of Oracle Procedural Gateway for APPC consists of several components:

  1. Oracle Integrating Server

    The Oracle Integrating Server is usually installed on the same system as Oracle Procedural Gateway for APPC.

    If you install the Oracle Integrating Server on a system other than the system on which the gateway is installed, then you must install Oracle Net with the Oracle Integrating Server and with the gateway. The Oracle Integrating Server must be capable of connecting to the gateway through any supported Oracle Net protocol.

    Refer to "Product Set" for a list of Oracle Net protocols currently supported by the gateway and tools.

    The Oracle Integrating Server can also be used for nongateway applications.

  2. The gateway

    Oracle Procedural Gateway for APPC must be installed on a server that can run the required version of the operating system.

  3. An OLTP

    The OLTP must be accessible from the gateway using the SNA or TCP/IP communication protocol. Multiple Oracle Integrating Servers can access the same gateway. A single system gateway installation can be configured to access more than one OLTP.

Figure 1-2 illustrates the architecture of Oracle Procedural Gateway for APPC using either SNA or TCP/IP, as described in the preceding section.

Figure 1-2 Gateway Architecture

Description of Figure 1-2 follows
Description of "Figure 1-2 Gateway Architecture"

1.5 Implementation of the Gateway

The basic structure of the gateway is the same whether your communications protocol is SNA or TCP/IP support for IMS Connect. The gateway has some of the same components as an Oracle database instance on Microsoft Windows. It has the following components:

The gateway does not have:

Because the gateway has no background processes and does not need a management utility such as Oracle Enterprise Manager, you do not need to start the gateway product. Each Oracle Integrating Server user session that accesses a particular gateway creates an independent process on Windows, which, in turn, runs the gateway server and executes either the SNA or TCP/IP functions to communicate with an OLTP.

1.6 Communication with the Gateway

All of the communication between the user or client program and the gateway is handled through a TIP which executes on an Oracle Integrating Server. The TIP is a standard PL/SQL package that provides the following functions:

The PGAU, provided with the gateway, automatically generates the TIP specification.

The gateway is identified to the Oracle Integrating Server using a database link. The database link is the same construct used to identify other Oracle server databases. The functions in the gateway are referenced in PL/SQL as:

function_name@dblink_name 

1.7 Remote Procedural Call Functions

The Oracle Procedural Gateway for APPC provides a set of functions that are invoked by the client through remote procedural call (RPC). These functions direct the gateway to initiate, transfer data with, and terminate RTPs running under an OLTP on another system.

Table 1-1 lists the RPC functions and the correlating commands that are invoked in the gateway and remote host.

Table 1-1 RPC Functions and Commands in the Gateway and Remote Host

Applications Oracle TIP Gateway Remote Host

call tip_init

tip_init

call pgainit@gateway

PGAINIT

Initiate program

call tip_main

tip_main

call pgaxfer@gateway

PGAXFER

Exchange data

call tip_term

tip_term

call pgaterm@gateway

PGATERM

Terminate program


1.7.1 Description of RPC Functions

The following sections describe how the RPC functions perform on gateways using SNA or TCP/IP communication protocols.

1.7.1.1 Remote Transaction Initiation

The TIP initiates a connection to the remote host system, using one of the gateway functions, PGAINIT.

When the communication protocol is SNA: PGAINIT provides, as input, the required SNA parameters to start a conversation with the target transaction program. These parameters are sent across the SNA network, which returns a conversation identifier to PGAINIT. Any future calls to the target program use the conversation identifier as an INPUT parameter.

When the communication protocol is TCP/IP: PGAINIT provides, as input, the required TCP/IP parameters. Use the pg4tcpmap tool to map the parameters. These parameters are sent across the TCP/IP network to start the conversation with the target transaction program, the TCP/IP network returns a socket file descriptor to PGAINIT. Future calls to the target program made by PGAXFER and PGATERM use the socket file descriptor as an input parameter.

Refer to Appendix B, "Gateway Initialization Parameters for TCP/IP Communication Protocol" in this guide, and to Chapter 6 in the Oracle Procedural Gateway for APPC User's Guide, for more information about the function and use of the pg4tcpmap tool.

1.7.1.2 Data Exchange

After the conversation is established, a procedural gateway function called PGAXFER can exchange data in the form of input and output variables. PGAXFER sends and receives buffers to and from the target transaction program. The gateway sees a buffer as only a RAW stream of bytes. The TIP that is residing in the Oracle Integrating Server is responsible for converting the application's PL/SQL datatypes to RAW before sending the buffer to the gateway. It is also responsible for converting RAW to the PL/SQL datatypes before returning the results to the application.

1.7.1.3 Remote Transaction Termination

When communication with the remote program is complete, the gateway function PGATERM terminates the conversation between the gateway and the remote host.

When the communication protocol is SNA:, PGATERM uses the conversation identifier as an INPUT parameter to request conversation termination.

When the communication protocol is TCP/IP:, PGATERM uses the socket file descriptor for TCP/IP as an INPUT parameter to request conversation termination.

1.8 Transaction Types for Gateway Using SNA

The Oracle Procedural Gateway for APPC supports three types of transactions that read data from and write data to remote host systems:

Refer to "Remote Host Transaction Types" in Chapter 4, "Client Application Development" of the Oracle Procedural Gateway for APPC User's Guide for more information about transaction types.

The following list demonstrates the power of the Oracle Procedural Gateway for APPC:

1.9 Transaction Types for Gateway Using TCP/IP

The Oracle Procedural Gateway for APPC using TCP/IP for IMS Connect supports three types of transaction socket connections: