Horizon TCP/IP
Overview
Model 204 TCP/IP (Horizon) provides a connection between Model 204 and PCs and workstations over a TCP/IP network. This connection transports requests and responses between the workstation clients and the Model 204 SQL Server on the mainframe.
You can use Model 204 TCP/IP (Horizon) and Windows Sockets (winsockets) to establish a client connection from a PC or workstation to the TCP/IP software on the mainframe. To use Model 204 TCP/IP (Horizon), you need installed and running on your PC or workstation an interface product that supports Windows Sockets.
Preparing the environment
To implement the Model 204 TCP/IP connection, prepare the Model 204 Online environment by defining TCP/IP SQL and RCL threads and adjusting buffer sizes. For information about preparation of the Model 204 Online, see Runtime environment for SQL processing.
In addition, you must specify the Model 204 TCP/IP link, processgroup, and process entities with Model 204 DEFINE commands. The procedures for creating these definitions are provided in this chapter.
Transparent operation
Once the network is properly defined, the operation of Model 204 TCP/IP is transparent to Connect★ users. For example, the execution of socket verbs is handled internally.
Connecting to Model 204 TCP/IP (Horizon)
The following figure shows a Model 204 TCP/IP link with three connections to Connect★ clients. Note the interrelated process, processgroup, and link that support TCP/IP connections.
In Model 204 TCP/IP, a conversation occurs over a connection in which the IP protocol for exchanging messages is observed.
See the DEFINE LINK command topic for information about the IP protocol.
In this chapter, descriptions of Model 204 TCP/IP use conversation and connection interchangeably, because a connection is dropped when a conversation ends. Model 204 TCP/IP conversation exchanges are always initiated by the Connect★ for an application program. CCARSQL is always the server.
Guidelines
- Model 204 SQL process accepts connection requests only from pre-specified TCP/IP clients.
- Model 204 TCP/IP processgroup definition specifies the network address or addresses of those clients with whom connections are possible.
- Model 204 link definition specifies the network address and port by which the Model 204 SQL server is known to the TCP/IP network.
- A single Model 204 TCP/IP link can support as many as 1999 connections at a time.
DEFINE commands
In Model 204 terminology, the Model 204 SQL Server is the server process, or program, that communicates through a conversation with a client partner (SQL application). The Model 204 DEFINE commands specify the physical and logical characteristics of the conversation and name the clients that can access the SQL Server.
The DEFINE commands--DEFINE LINK, DEFINE PROCESS, and DEFINE PROCESSGROUP--are all necessary to define a Horizon for TCP/IP connection.
Issuing DEFINE commands
The DEFINE commands are typically stored in a SOUL procedure that is invoked by the Model 204 Online job or EXEC at runtime or coded in the Online job or EXEC CCAIN stream. For example,
DEFINE PROCESS CCARSQL WITH SCOPE = SYSTEM - DATALEN = 32763 FROM = (ANY192, ANY204)
The CCAIN settings defined for the SQL thread(s) are used as default settings for the RCL thread(s). They can also be issued Online from Model 204 command level by a user with system manager privileges.
Exchanging Horizon for TCP/IP connection parameters
The Model 204 system manager and TCP/IP system administrator must exchange or jointly determine certain parameter values required to define their connection. ion characteristics are provided by default.
As summarized in the following table, Model 204 DEFINE command parameters must specify server and client network addresses, the server port number, and connection buffer sizes. For 32-bit * interfaces, ODBC SQL and SQLDriver function calls also specify the server's network address and port number, and might specify a Model 204 user ID and password.
Value provided | Model 204 DEFINE command parameter | TCP/IP client specification |
---|---|---|
Server node (Model 204 SQL) address | DEFINE LINK LOCALID |
Host (Server) Name or IP Address parameter in ODBC, JDBC or .NET connection string |
Server port number | DEFINE LINK SERVPORT |
Port number parameter in ODBC, JDBC or .NET connection string |
Client node (TCP/IP Workstation) address | DEFINE PROCESSGROUP REMOTEID MASK |
N/A |
Model 204 user ID and password for client user (might not be required) | Login depends on setting of: DEFINE PROCESSGROUP LOGIN |
User ID and password in ODBC, JDBC or .NET connection string |
For details about TCP/IP client specification, see Connect★ installation requirements.
DEFINE command interconnections
Specify a DEFINE command for each Horizon network entity. Each command has multiple parameters, some of which are optional.
The Horizon network entities are described in the following table.
Entity | Description |
---|---|
Link | Identifies the local node (with LOCALID parameter and SERVPORT parameter) |
Processgroup | Points to the link (with LINK) and points to the client node (with REMOTEID and, optionally, MASK) |
Process | Model 204 SQL process (CCARSQL) points to the processgroups (with FROM) |
The following figure shows the parameters with which the commands point to each other and to the client partner. Descriptions of the individual entity definitions with all their parameters are provided in previous sections of this topic.
OPEN LINK command
After you have issued the required entity definition commands, you must issue the OPEN LINK command to enable processing.
The OPEN LINK command prepares a port to accept connection requests. Connection requests are accepted and processed only if the address they come from matches the (masked) address in a processgroup definition that points to an open link.