ASSIGN_PROCESS_TO_JOB - UCMD Server configuration option

Description

The ASSIGN_PROCESS_TO_JOB option controls the startup and shutdown behavior of UCMD Server processes executed on Windows.

  • If ASSIGN_PROCESS_TO_JOB is set to yes, UCMD Server assigns all of its child processes to a system resource known as a job object.
  • If ASSIGN_PROCESS_TO_JOB is set to no, child processes are not assigned to a job object, and no relationship among parent / child processes is maintained.

ASSIGN_PROCESS_TO_JOB simplifies process management by forcing all child processes to end whenever a user terminates UCMD Server. Prior to UCMD Server 3.2.0.0, the only child process guaranteed to terminate along with UCMD Server was its immediate, well-known child process, cmd.exe. Consequently, its child process (that is, the command or script specified from UCMD Manager) could continue to run even after cancelling UCMD Server. When cancelling a UCMD Server that assigns its well-known child process to a job, the entire process tree ends.

If the command or script specified from UCMD Manager must continue to run even after cancelling a UCMD Server, simply set ASSIGN_PROCESS_TO_JOB to no. In that case, process termination behaves exactly as it did prior to UCMD Server 3.2.0.0.

Note

The affect of ASSIGN_PROCESS_TO_JOB on UCMD Server's behavior is limited to Server cancellation. All other UCMD Server behavior – including, but not limited to, standard I/O redirection, network and host fault tolerance, and detection of process completion – is unchanged.

Although ASSIGN_PROCESS_TO_JOB is available only for a Windows UCMD Server, a UCMD Manager (3.2.0.0 or later) on any operating system can override it for any single UCMD Server instance.


A Stonebranch Tip

Assigning a UCMD Server child process to a job means that Windows will automatically assign all processes that child spawns to that job.

If any of those child processes creates its own job object with the expectation that it is not part of any other job, some unexpected behavior may occur.

In these situations, either set ASSIGN_PROCESS_TO_JOB to no\ or change the application's behavior.

For more information, refer to Windows Platform SDK documentation for the CreateProcess, CreateProcessAsUser, and IsProcessInJob functions, and the CREATE_BREAKAWAY_FROM_JOB and JOB_OBJECT_LIMIT_BREAKAWAY_OK options.

Usage

Method

Syntax

IBM i

UNIX

Windows

z/OS

Configuration File Keyword

assign_process_to_job option



(tick)


Manager Override

-assign_process_to_job option

(tick)

(tick)

(tick)

(tick)

Values

option is the specification for whether or not UCMD Server child processes are assigned to a job.

Valid values for option are:

  • yes
    Create a job object and assign all UCMD Server child processes to it.
  • no
    Do not create a job object.

Default is yes.