HCL Workload Automation, Version 9.4

release

Run the release utility on a master domain manager or a fault-tolerant agent workstation (not supported on dynamic agents) to release jobs and job streams from needs dependencies on a resource. This command must be issued only from within the job script file. This command is effective only if the target jobs and job streams are running when the command is issued. If you rerun the job or job stream, the required resources are allocated again. All product components must be at least at the Version 9.4 level.

Syntax

release -V | -U

release
      [-s| -schedule]
      [workstation#]
      resourcename
     [count]

Arguments

-V
Displays the command version and exits.
-U
Displays command usage information and exits.
-s | -schedule
Releases the needs dependency from the specified resource only at the job stream level.

If -s is not used, the needs dependency from the specified resource is released at the job level, or at the job stream level if the needs dependency from that resource is not found at the job level.

workstation#
Specifies the name of the workstation or workstation class on which the resource is defined. The default is the local workstation.
resourcename
Specifies the name of the resource involved in the needs dependency.
count
Specifies the number of units of the resource to be released. If no number is specified, all resources are released.

Comments

Units of a resource are acquired by a job or job stream at the time it is launched and are released automatically when the job or job stream completes. The release command can be used in a job script to release resources before job or job stream completion or to release manually jobs and job streams from needs dependencies in emergency situations.

Examples

In the following job stream, two units of the dbase resource are required by job stream sked5:
schedule ux1#sked5 on tu
needs 2 dbase :
job1
jobrel follows job1
job2 follows jobrel
end
To release the dbase resource before job2 begins, the script file for jobrel contains the following command:
On UNIX operating systems:
ˋmaestroˋ/bin/release -s dbase
On Windows operating systems:
<TWS_home>\bin\release -s dbase
Note: The -s argument can be omitted, because no resources were reserved at the job level.

The following example demonstrates how to partially release resources at the job stream level.

In the following job stream, four units of the dbase resource are required by job stream sked5:
schedule ux1#sked5 on tu
needs 4 dbase :
job1
jobrel follows job1
job2 follows jobrel
end
To release the dbase resource before job2 begins, the script file for jobrel contains the following command:
On UNIX operating systems:
ˋmaestroˋ/bin/release -s dbase 3
On Windows operating systems:
<TWS_home>\bin\release -s dbase 3

In this case, while job job1 is running, the number of resources required by the ux1#sked5 job stream is 4. When job jobrel starts, launching the release command, the number of resources in use changes to one, because the release command has released three resources.

The following is the output of the conman sr @#@ command launched while job1 is running:
%sr @#@
CPU#Resource   Total Available Qty UsedBy
UX1#DBASE      10    6         4   UX1#SKED5[(1032 11/03/16),(0AAAAAAAAAAAAABM)]
The following is the output of the conman sr @#@ command launched after the second job (jobrel) in the job stream has completed, and before the last job (job2) in the job stream completes:
%sr @#@
CPU#Resource   Total Available Qty UsedBy
UX1#DBASE      10    9         1   UX1#SKED5[(1032 11/03/16),(0AAAAAAAAAAAAABM)]

The following example demonstrates how to completely release resources at the job stream level.

In the following job stream, four units of the dbase resource are required by job stream sked5:
schedule ux1#sked5 on tu
needs 4 ux1#dbase :
job1
jobrel follows job1
job2 follows jobrel
end
To release the dbase resource before job2 begins, the script file for jobrel contains the following command:
On UNIX operating systems:
ˋmaestroˋ/bin/release -s dbase 4
On Windows operating systems:
<TWS_home>\bin\release -s dbase 4

In this case, while job job1 is running, the number of resources required by the ux1#sked5 job stream is 4. When job jobrel starts, launching the release command, the number of resources in use changes to zero, because the release command has released all four resources. You can obtain the same result by specifying a higher number of resources than are actually required by the job stream or by specifying no number at all: in both cases, the command releases all resources required by the job stream.

The following is the output of the conman sr @#@ command launched while job1 is running:
%sr @#@
CPU#Resource   Total Available Qty UsedBy
UX1#DBASE      10    6         4    UX1#SKED5[(1040 11/03/16),(0AAAAAAAAAAAAABM)]
The following is the output of the conman sr @#@ command launched after the second job (jobrel) in the job stream has completed, and before the last job (job2) in the job stream completes:
%sr @#@
CPU#Resource       Total Available  Qty UsedBy
UX1#DBASE          10    10         No holders of this resource

The following example demonstrates how to partially release resources at the job level.

In the following job stream, four units of the dbase resource are required by job jobrel:
schedule ux1#sked5 on tu
:
job1
jobrel follows job1
needs 4 fta1#dbase
job2 follows jobrel
end
To release the dbase resource before job2 begins, the script file for jobrel contains the following command:
On UNIX operating systems:
ˋmaestroˋ/bin/release dbase 1
On Windows operating systems:
<TWS_home>\bin\release dbase 1

In this case, while job job1 is running, the number of required resources is zero. As soon as job jobrel starts and before the release command it contains is launched, the number of resources in use changes to four. When the release command in job jobrel is launched, the number of resources in use changes to three because the release command has released one resource.

The following example demonstrates how to partially release resources at the job stream level.

In the following job stream, 34 units of the dbase resource are required by job jobrel:
schedule ux1#sked5 on tu
needs 34 dbase
:
job1
jobrel follows job1
job2 follows jobrel
end
To release the dbase resource before job2 begins, the script file for jobrel contains the following command:
On UNIX operating systems:
ˋmaestroˋ/bin/release dbase
On Windows operating systems:
<TWS_home>\bin\release dbase

In this case, while job job1 is running, the number of resources required by job stream ux1#sked5 is 34. When job jobrel starts, the number of resources in use changes to two. This happens because the products divides the resources into blocks formed by 32 units. The dependency from 34 resources is evaluated by Workload Scheduler as a double dependency: the first dependency having 32 units, and the second one having two units. When the release command in job jobrel is launched, the number of resources in use changes to two because the release command (for which no quantity has been defined) has completed released the first dependency, containing 32 units.

The following is the output of the conman sr @#@ command launched while job1 is running:
%sr @#@
CPU#Resource  Total Available  Qty UsedBy
UX1#DBASE     34    0          34   UX1#SKED5[(1101 11/03/16),(0AAAAAAAAAAAAABR)]
The following is the output of the conman sr @#@ command launched after the second job (jobrel) in the job stream has completed, and before the last job (job2) in the job stream completes:
%sr @#@
CPU#Resource  Total Available  Qty UsedBy
UX1#DBASE     34    32          2   UX1#SKED5[(1101 11/03/16),(0AAAAAAAAAAAAABR)]

The following example demonstrates the internal working of the product and why no resource release occurs in this case

In the following job stream, four units of the dbase resource are required by job job1:
schedule ux1#sked5 on tu
:
job1
needs 4 dbase
jobrel 
job2 follows jobrel
end
To release the dbase resource before job2 begins, the script file for jobrel contains the following command:
On UNIX operating systems:
ˋmaestroˋ/bin/release dbase 2
On Windows operating systems:
<TWS_home>\bin\release dbase 2

In this case, job job1 requires four resources. When job jobrel starts, the release command it contains does not have any effect because no resource dependency is present for job jobrel . This happens because the release command releases resources only for the job instance which runs the command. In the case that other jobs or job streams, or other instances of the same job which launches the release command, are using units of a specific resource, such units are not released, even when the resource in use matches the resource name in the command.