Configure the scheduler to run a job on an instance or cluster member

We can configure the WebSphere Commerce scheduler to run a job on a particular WebSphere Commerce instance or cluster member. This can be useful to devote one server for scheduled jobs.


Task info

To isolate a scheduled job to a particular instance or cluster member:

To uniquely identify each server process running WebSphere Commerce, the following JVM parameter is required:

The value should be unique across all servers running the WebSphere Commerce instance. This will allow you to created a scheduled job that runs on a particular server in the cluster. A recommended value would be: node name. server name. This will be unique across the WebSphere Cell.

This value can be specified using the WebSphere Application Server Administrative Console and specifying this system property in the JVM settings of the WebSphere Commerce application:

To create a job to run on a particular host, when calling the AddJob command to create the new schedule job, specify the host parameter and use the value that uniquely identifies the scheduler process that should execute the scheduled job.

To manually change an existing job, update the SCCHOST column in the SCHCONFIG table for the job we want to run on a particular instance. When changing the SCCHOST column, ensure that the value is specified in lowercase characters. Because of performance reasons, the scheduler assumes that the host parameter will be specified in lowercase. The AddJob command makes the host value lowercase automatically but there is nothing in place at the database to maintain this restriction.

In the development or test environment, to configure the scheduler to run a job on one host, perform the following steps for each node in the cluster:


Procedure

  1. Open the WebSphere Application Server Administrative Console.

      Servers | Application Servers | Transaction Server | Application Servers | Server Infrastructure | Java and Process Management | Process Definition | Additional Properties | Java Virtual Machine | Additional Properties | Custom Properties | New

  2. In the Name field, enter...

      com.ibm.commerce.scheduler.SchedulerHostName

  3. In the Value field, enter the unique identifier of the scheduler instance on this Java process.

  4. In the Description field, enter the host name parameter for this scheduler instance to use.


Related tasks
Schedule a site-level job