HCL Workload Automation, Version 9.4

< Previous

Specifying software license requirements by using resources

In this scenario, a job requires two software licenses to run. Using logical resources to represent license availability, a company ensures compliance to license requirements.

Business Goal

A company runs a job that uses two licensed software products. Product SoftwareA is licensed under a node-locked license agreement, for which the company has four entitlements assigned to ComputerA, ComputerB, ComputerC, and ComputerD. For product SoftwareB, the company has a floating license, for which there are three entitlements available to all computers in the network. The job is submitted ensuring compliance to the licensing policies.

Roles

This section lists the user roles needed to run the scenario:
dynamic workload broker Developer
Defines the jobs using the Job Brokering Definition Console
dynamic workload broker Operator
Monitors and controls the jobs that have been submitted.
HCL Workload Automation Job Scheduler
Manages the workload by submitting and monitoring jobs.

Software requirements

The following software must be installed and configured, before running this scenario:
  • A HCL Workload Automation network with the dynamic scheduling capability.
  • Optionally, the Dynamic Workload Console.

Setting up the environment

To run this scenario, complete the tasks described in Setting up your environment for dynamic scheduling.

Running the Scenario

Before you begin

Before creating the job, the administrator uses the Define a New Logical Resource Task option in the Dynamic Workload Console to create the logical resources, as shown in Table 1. The node-locked license logical resources are each assigned to a computer and the quantities specified can only be used by jobs running on the specified computer. The floating license logical resource is a global resource. It is not assigned to a computer and can be accessed by a job running on any computer until the total quantity is used.
Table 1. Logical resources for controlling license availability
logical resource name Type Quantity Computer
locked_license1 SoftwareA 1 ComputerA
locked_license2 SoftwareA 1 ComputerB
locked_license3 SoftwareA 1 ComputerC
locked_license_4 SoftwareA 1 ComputerD
floating_license SoftwareB 3 None
To create a job definition that uses these logical resources to include license requirements, perform the following steps:

Procedure

  1. In the Job Brokering Definition Console, select File > New > Job Brokering Definition and create a new job definition named jobThatConsumesLicenses. The job definition opens at the Overview page with the job name assigned.
  2. Open the Application page and define the required information for the application that the job is to run.
  3. Open the Resources page and select the Software Requirements tab.
  4. Create a requirement for a SoftwareA logical resource, as follows:
    1. In the Logical Resources pane, click Add. The Logical Resource Details dialog box is displayed.
    2. In the Type field, type SoftwareA and click OK . The Logical Resource details are displayed.
    3. In the Logical Resource details area, specify 1 in the quantity field.
  5. Open the Related Resource page and create a requirement for the SoftwareB logical resource, as follows:
    1. In the Resource Requirements pane, click Add. The Resource Requirement Details dialog box is displayed.
    2. In the ID field, specify a meaningful ID, in this example, Floating_Global_License.
    3. In the Type field, select Logical Resource and click OK.
    4. In the Resource Properties pane, click Add Requirement. The Resource Requirement Details dialog box is displayed.
    5. Select Subtype from the Property name menu, type SoftwareB in the Property Value field, and click OK.
    6. In the Allocations pane, click Add. The Allocations Details dialog box is displayed.
    7. Select Quantity from the Property name menu, type 1 in the Quantity field, and click OK.
  6. Select File > Save to save the job definition file.
  7. Select the new JSDL and upload it to the server by clicking on the corresponding icon.
  8. Submit the job proceeding in one of the following ways, depending on whether you want to submit it as a broker job or using a job definition.
    • Log in to the Dynamic Workload Console and choose the Dynamic Workload Broker portfolio option.
      • Select Definitions > Jobs Optionally specify search criteria and click Search. Select the job definition that you created in the previous steps.
      • To run the job, select Submit and click Go.
    • Log in to the Dynamic Workload Console.
      • Select Administration > Workload Design > Manage Workload Definitions. In the Workload Designer, create a new broker job definition filling in the required fields as appropriate. In the Workload Broker Job Name field, type the name of the JSDL file you created in steps 1 through 7.
      • Submit the job by selecting Administration > Workload Submission > Submit Predefined Jobs .
      You can also add the job to an existing job stream , or submit the job using the jobsubmit command. For further information about the dynamic workload broker command-line interface, see HCL Workload Automation: Scheduling Workload Dynamically.

Expected Results

When the jobs are submitted, they are sent to one of the nodes having a node-locked license and using one of the floating global licenses, in accordance with the licensing policies. With the settings used in this scenario, the maximum number of jobthatConsumesLicenses instances that can run concurrently is 3 because each of them are allocated a floating license of SoftwareB. The instances can either run on the same or on different computers holding the node-locked license of SoftwareA.

Sample Configuration file

The JSDL file created for this scenario has the following syntax:
<?xml version="1.0" encoding="UTF-8"?>
<jsdl:jobDefinition xmlns:jsdl="http://www.ibm.com/xmlns/prod/scheduling/1.0/jsdl"
  xmlns:jsdle="http://www.ibm.com/xmlns/prod/scheduling/1.0/jsdle"
    name="jobThatConsumesLicences">
  <jsdl:variables>
    <jsdl:stringVariable name="myApp">sleep</jsdl:stringVariable>
  </jsdl:variables>
  <jsdl:application name="executable">
    <jsdle:executable interactive="false" path="${myApp}">
      <jsdle:arguments>
        <jsdle:value>120</jsdle:value>
      </jsdle:arguments>
    </jsdle:executable>
  </jsdl:application>
  <jsdl:resources>
    <jsdl:logicalResource quantity="1" subType="SoftwareA"/>
  </jsdl:resources>
  <jsdl:relatedResources id="Floating_Global_License" type="LogicalResource">
    <jsdl:properties>
      <jsdl:requirement propertyName="SubType">
        <jsdl:exact>SoftwareB</jsdl:exact>
      </jsdl:requirement>
    </jsdl:properties>
    <jsdl:allocation propertyName="Quantity">1.0</jsdl:allocation>
  </jsdl:relatedResources>
</jsdl:jobDefinition>
< Previous