Guardian Procedure Calls Reference Manual (G06.25+)

Guardian Procedure Calls (P)
Guardian Procedure Calls Reference Manual522629-013
12-166
PROCESS_SPAWN_ Procedure
PROCESS_SPAWN_ Procedure
Summary
Syntax for C Programmers
Syntax for TAL Programmers
Parameters
Structure Definition for fdinfo
Structure Definition for inheritance
Structure Definition for process-extension
Structure Definition for process-results
Nowait Considerations
Considerations for Resolving File Names
Considerations for Resolving External References
Considerations for Reserved Names
Keeping Track of OSS Child Processes
Creator Access ID and Process Access ID
Compatibility Considerations
DEFINE Considerations
Batch Processing Considerations
Safeguard Considerations
Related Programming Manuals
Summary
The PROCESS_SPAWN_ procedure creates a new Open System Services (OSS)
process and, optionally, assigns a number of process attributes. You can use this
procedure to create only OSS processes, although you can call it from either a
Guardian process or an OSS process. To create a Guardian process, call the
PROCESS_LAUNCH_ procedure.
DEFINEs can be propagated to the new process. The DEFINEs can come from the
caller’s context or from a buffer of DEFINEs saved by the DEFINESAVE procedure.
PROCESS_SPAWN_ differs from the OSS functions that create OSS processes in the
following ways:
You can specify that the new process be created in either a waited or nowait
manner. When it is created in a waited manner, identification for the new process
is returned directly to the caller. When it is created in a nowait manner, its
identification is returned in a system message sent to the caller’s $RECEIVE file.
You can obtain a level of fault tolerance in OSS processes by calling
PROCESS_SPAWN_ to create OSS processes from a monitor implemented as a
Guardian process pair. The monitor checks that the created OSS process
continues to run and restarts it if there is a failure. For more information on writing
fault-tolerant programs, refer to the
Guardian Programmer’s Guide.
Note. The TAL or pTAL syntax for this procedure is declared only in the EXTDECS0 file.