Server Processes

A server is a single NCL process that can accept connections from one or more clients, either serially or concurrently, at the server's discretion. Registration of the server is successful if the server name is unique within some scope, as determined by the server name registration request. Registration of the server name can be tied to process creation such that if the registration is unsuccessful the process creation fails. Alternatively, an executing process can attempt to register itself as a server at any time.

A transaction that starts an NCL procedure can now indicate, through the Transaction Control Table, that, once attached, the target NCL procedure is to be registered as a server process. A server process can also be started by the usual START command before any communication is necessary.

In general, any NCL process, regardless of whether or not it has a registered server process name, can in fact behave as a server process. That is, any active NCL process can accept client connections. Server name registration provides a mechanism for preventing duplication of server processes, but, more importantly, assists in targeting the correct server by supplying a meaningful name. While a server is active, new transactions can target the process and request connection. Such transactions can, at the server's discretion, be queued to the server through the APPC transfer mechanism in your product or automatically connected to the server for immediate operation.

Any process that has a registered server name can be targeted, by defining transactions in the TCT that allocate that particular server name. If the server is not active, the first transaction selecting a TCT entry for that server name will start the server process. Subsequent transactions locate the active server process and queue a connection request. Any user defined transaction can target a server in this manner. In addition, the ATTACH and CONNECT transactions allow a server to be targeted by the requestor.


Copyright © 2010 CA. All rights reserved.