HCL Workload Automation, Version 9.4

Inclusive and exclusive rule-based run cycles

This scenario shows how a HCL Workload Automation administrator can use subsets of run cycles in a run cycle group to achieve a specific workload schedule that, without the use of a run cycle group, would require the definition of numerous run cycles, calendars, or both. In addition, it demonstrates how you can reuse run cycle groups in different job streams and add an offset to shift a workload schedule forward by one day.

Scenario goal

In this scenario, a HCL Workload Automation administrator needs to run a process that elaborates sales projections every day except Friday, and on the first day of each month; in the latter case, it must run even if the first day of the month is a Friday. The administrator must then run a post-sales check according to the same schedule but a day later.

Business Scenario

To define the required workload schedule, the HCL Workload Automation administrator creates a run cycle group with two subsets. The first subset defines that the process must run every day except Fridays, and the second subset defines that the process must run on the first day of each month, even if the first day of the month is a Friday. The same run cycle group is reused in a different job stream to run a post-sales check, however, this job stream should follow the same schedule as the sales projections, but one day later.

Roles

This section lists the user roles needed to run the scenario:

HCL Workload Automation Developer
Defines the run cycle groups in a job stream.
HCL Workload Automation Job Scheduler
Manages HCL Workload Automation workload by submitting and monitoring jobs.

Software Requirements

The following software must be installed and configured, before running this scenario:
  • HCL Workload Automation version 9.1.
  • Dynamic Workload Console version 9.1.

Setting up the environment

To run this scenario you must install or upgrade to HCL Workload Automation version 9.1.

Running the Scenario

To complete the scenario, perform the following steps:

About this task

Procedure

  1. Define the run cycle group that will contain the two subsets.
    1. In the Working List pane, select New > Run cycle group.
    2. In the Properties pane, specify the properties for the run cycle group definition you are creating using the tabs available. For more detailed information about the UI elements on each tab, see the Dynamic Workload Console online help.
    3. On the General tab, specify general information about the run cycle group definition such as the name, SalesProjections.
    4. On the Time restrictions tab, specify time restrictions for the job stream associated to the run cycle group.
    5. Save the run cycle group definition.
  2. Create a subset within which to create two run cycles. The first to run the process on a daily basis, and the second to exclude Fridays.
    1. Right-click the run cycle group SalesProjections and click Add Subset. By default, the subset name is SUBSET-1, but you can optionally modify the name.
    2. Right-click SUBSET-1 and click Add Run Cycle.
    3. On the General tab, specify general information about the run cycle definition such as the name, DailyProcess.
    4. Leave the default selection for Inclusive or Exclusive Run Cycle as Inclusive.
    5. On the Rule tab, specify Daily for the Repeat schedule, and leave the default selection 1 for Run every selected number of days and Everyday for On the following day type.
    6. Save the run cycle group definition.
    7. Right-click SUBSET-1 again and click Add Run Cycle to add a second run cycle that excludes Friday from the daily process.
    8. On the General tab, specify general information about the run cycle definition such as the name, NoFridays.
    9. In Inclusive or Exclusive Run Cycle select Exclusive since this run cycle serves to exclude Fridays.
    10. On the Rule tab, specify Weekly for the Repeat schedule, and select Friday for On the following days of the week.
    11. Save the run cycle group definition. You can click the Run Cycle Preview tab to view the schedule for each of the run cycles and then the combination of the run cycles on a calendar.
  3. Create a second subset to define a run cycle to run the process on the first day of each month.
    1. Right-click the run cycle group SalesProjections and click Add Subset to add a second subset. By default, the subset name is SUBSET-2, but you can optionally modify the name.
    2. Right-click SUBSET-2 and click Add Run Cycle.
    3. On the General tab, specify general information about the run cycle definition such as the name, FirstDayoftheMonth.
    4. Leave the default selection for Inclusive or Exclusive Run Cycle as Inclusive.
    5. On the Rule tab, specify Monthly by month day for the Repeat schedule, and 1st Day for On the (ascending order).
    6. Save the run cycle group definition.
  4. Create a job stream containing the jobs to run the sales projections processes and then associate the run cycle group, SalesProjections, by adding a run cycle containing a repeat schedule set to Run Cycle Group.
    1. From the Working List click New > Job Stream.
    2. Define a name and the workstation for the job stream.
    3. Click Select an Action > Add Jobs.
    4. Search for and select the jobs related to the sales projections processes and click Add.
    5. Select the job stream in the Details view, and click Select an Action > Add Run Cycle.
    6. Define a name for the run cycle.
    7. On the Rule page, select Run Cycle Group for the Repeat schedule.
    8. Search for and select the run cycle group SalesProjections and click OK.
    9. Save the job stream definition Click Run Cycle Preview to view a calendar displaying the run cycle schedule for the job stream.
  5. Reuse the same run cycle group in a different job stream that runs a post-sales check according to the same run cycle schedule but a day later.
    1. Define a new job stream or open an existing job stream containing the jobs to run the post-sales check, and add a run cycle to the job stream specifying the SalesProjections run cycle group as the rule for the job stream.
    2. In the Offset section on the Rule page, click the up arrow to specify an offset of 1 day. Click Run Cycle Preview to display the same run cycle schedule used in the sales projections job stream but with the dates shifted over by one day.

Expected result

You have created a job stream with a run cycle group containing two subsets that create a workload schedule that runs a process every day except Friday and the first day of each month, even if the first day falls on a Friday. The same run cycle group is used to run a different process but a day later with respect to the first job stream.