This document describes how to operate a Natural Development Server in a Com-plete on z/OS environment.
The following topics are covered:
A prerequisite is a running Com-plete address space that is configured to run the Natural Development Server (see Development Server Installation).
Start the Natural Development Server with the Com-plete console command
F name,NATRDEVS <server-id>
- where
name is the address space name assigned to the
Com-plete region,
server-id is the name of your Natural
Development Server.
F COMPLETE,NATRDEVS NDVS1
Note
If you qualify the Natural Development Server datasets by
server-id, the server ID is restricted to a maximum length
of 6 characters.
Alternatively, you can automatically start Natural Development Servers during Com-plete
initialization by using the Com-plete SYSPARM parameter
STARTUPPGM. In the Com-plete SYSPARM file
specify:
STARTUPPGM='NATRDEVS <server-id>'
STARTUPPGM='NATRDEVS NDVS1'
The Natural Development Server can be terminated from within the Monitor Client NATMOPI, see Monitor Commands.
Active Natural Sessions are canceled by issuing cancel session commands. If, at the time of the
Natural Development server shutdown, no Natural session is active on that Natural
Development server, then no cancel session command is issued.
Natural Development server only uses the cancel session command for sessions that are
currently executing a Natural session (e.g. using Run
As/Debug As) or using the Natural Command
Console for Mainframes. It is only required for active Natural sessions that
are not sitting on a terminal I/O. They must either be sitting on a wait inside Natural or
looping.
To enable the administrator to monitor the status of the Natural Development Server, a monitor task is provided which is initialized automatically at server startup. Using the monitor commands described below, the administrator can control the server activities, cancel particular user sessions, terminate the entire server, etc.
The following topics are covered below:
To communicate with the monitor, you can use the monitor client NATMOPI;
see Monitor Client
NATMOPI.
Alternatively, you can use the operator command MODIFY to
execute the monitor commands described below in the section Monitor Commands. The output of
the executed monitor command will be written to the system log.
F jobname,APPL=ping
sends the command ping to the NDV server running under the
job jobname.
The Natural Development Server supports the following monitor commands:
| Monitor Command | Action |
|---|---|
ping |
Verifies whether the server is active. The server responds and sends the
string I'm still up |
terminate |
Terminates the server. |
abort |
Terminates the server immediately without releasing any resources. |
set configvariable
value |
With the set command, you can modify server
configuration settings. For example, to modify
TRACE_LEVEL:
set TRACE_LEVEL 31+30+15 |
list sessions |
Returns a list of active Natural sessions within the server. For each
session, the server returns information about the user who owns the session, the
session initialization time, the last activity time and an internal session
identifier (session-id).
|
list cputime |
Returns a list of transactions with highest CPU time usage, sorted by CPU
time in descending order. See CPU_TIME_HISTORY and CPU_TIME_TRACE to
enable CPU time history.
|
cancel session
session-id |
Cancels a specific Natural session within the Natural Development Server. To
obtain the session ID, use the monitor command |
cleanup |
Cancel sessions that are inactive longer than specified in configuration
parameter SESSION_TIMEOUT.
|
help |
Returns help information about the monitor commands supported. |
For debugging purposes, the server code has a built-in trace facility which can be switched on, if desired.
The following topics are covered below:
A remote development server writes its runtime trace to Com-plete job output into the dataset
srvnameT.
The trace is configured by a trace level
which defines the details of the trace. Once a trace is switched on, it can be
restricted to particular clients or client requests by specifying a trace filter, see also NDV configuration parameter
TRACE_FILTER.
Every Natural session is provided with a 32-bit trace status word (TSW) which defines
the trace level for this session. The value of the TSW is set in the NDV configuration
parameter TRACE_LEVEL. A value of zero means that the trace is
switched off.
Each bit of the TSW is responsible for certain trace information. Starting with the rightmost bit:
| Bit 31 | Trace main events (server initialization/termination, client request/result). |
| Bit 30 | Detailed functions (session allocation, rollin/rollout calls, detailed request processing). |
| Bit 29 | Dump internal storage areas. |
| Bit 28 | Session directory access. |
| Bit 27 | Dump request/reply PAL buffer. |
| Bit 26 | Free. |
| Bit 25 | Dump I/O buffer. |
| Bit 24 | Free. |
| Bit 23 | Request processing main events. |
| Bit 22 | Request processing detailed functions. |
| Bit 21 | Remote debugger main events. |
| Bit 20 | Remote debugger detailed functions. |
| Bit 19-16 | Free. |
| Bit 15 | Trace error situations only. |
| Bit 14 | Apply trace filter definitions. |
| Bit 13 | Trace start and termination of the server only. |
| Bit 12 | Trace start and termination of the client sessions only. Even if bit 13 is set. |
| Bit 11-08 | Free. |
| Bit 07-01 | Free. |
| Bit 00 | Reserved for trace-level extension. |
It is possible to restrict the trace by a logical filter in order to reduce the volume of the server trace output.
The filter can be set with the configuration parameter
TRACE_FILTER.
The filter may consist of multiple
keyword=filtervalue assignments separated
by spaces.
To activate the filter definition, the trace bit 14 in the trace status word (see Trace Level) must be set.
The filter keyword is:
Client |
Filters the trace output by specific clients. |
The following rules apply:
If a keyword is defined multiple times, the values are cumulated.
The value must be enclosed in braces and can be a list of filter values separated by spaces.
The values are not case sensitive.
Asterisk notation is possible.
TRACE_FILTER="Client=(KSP P*)"
Each request of the user ID KSP and each request of the user IDs starting
with a P are traced.