Customizing jobs and job streams based on when they are scheduled to run
This scenario shows how to customize jobs and job streams based on when they are scheduled to run, that is on which days they run, using variable tables referenced at the run cycle level.
- A single job stream with two run cycles, referencing two different variable tables.
- File dependencies on jobs using variables, forcing instances generated on a specific day to use different variable values with respect to instances generated on another day.
- A variable in the path of the scriptname job attribute.
Using variable tables you reduce the number of scheduling object definitions required to implement your workload saving time and money.
Using variable tables you need to define less scheduling objects required to implement your workload with respect to the past saving time and money.
You can find more information on this subject in the User's Guide and Reference.
Scenario goal
The files containing the input data needed to generate the reports are stored in two different directories, and the job stream used to generate reports has a dependency on these files. To collect data you can now create one job stream with two different run cycles (one that runs weekly and one that runs monthly) that reference two different variable tables containing a variable that is in the file path.
Roles and skills
- HCL Workload Automation Job Scheduler
- Manages Tivoli Workload Scheduler workload. Required skills include Tivoli Workload Scheduler knowledge.
System requirements
Install the following software before starting the scenario:- HCL Workload Automation version 8.5
- Dynamic Workload Console version 8.5
Setting up the environment
- Install and configure HCL Workload Automation version 8.5
- Install and configure Dynamic Workload Console version 8.5
Running the Scenario
To complete the scenario, perform the following steps:
Procedure
Expected results
The REP_PATH variable assumes different values according to the run cycle that applies, that is according to the variable table referenced in the corresponding run cycle.
- The job stream instances that generate the weekly report have a dependency on the file containing the data located in the directory /reports/weekly.
- The job stream instances that generate the monthly report have a dependency on the file containing the data located in the directory /reports/monthly.
- The jobs run by job stream instances that generate the weekly report run shell scripts with the /reports/weekly directory as an input argument.
- The jobs run by job stream instances that generate the monthly report run shell scripts with the /reports/monthly directory as an input argument.