Enterprise Manager: BBjServices > Scheduling

To view this topic for the preceding Enterprise Manager, see EM Java App: Server Information (Autorun Tab).

Description

Scheduling provides administrators the ability to execute one or more tasks and/or programs at designated times and with a optional repeat frequency. One benefit for using the built-in scheduling feature as opposed to something such as CRON is that the scheduling interface makes it easy to run a BBj program, pause a replication job, or resume a replication job.

To access BBjServices Scheduling, double-click 'Scheduling' in the BBj EM Navigator and the scheduling tab opens to the right.

Task Groups

Task Groups provide a mechanism for grouping together one or more tasks to perform at a given point in time. The task group can be executed at BBj startup (also know as “autorun”), at a particular date and time, on particular days of the week, etc.  In addition, administrators can configure the task group execution to repeat at a given interval. Task Groups contain the following basic information:

  • List of one or more Tasks to be executed synchronously in sequential order
  • When the Task Group should first execute
  • How often the Task Group should repeat execution

Tasks

A Task is a single item to be managed and executed by a Task Group. There are several types of Tasks available to the scheduler: BBj Program, Execute System Call, Pause Replication Job, and Resume Replication Job.

Task Type - BBj Program

A BBj Program task defines a BBj program file to be executed as well as execution parameters, classpath, config file, etc. The task returns when the program exits. Programs can be as complex as necessary and CALL other programs or execute SCALL commands. The only limitation is that GUI operations should not be used since the program will be run server side with no user interaction.

The Task Editor provides a way to configure the various program options and settings.


Task Type

Type of task to use: BBj Program, Execute System Call, Pause Replication Job, or Resume Replication Job.

Program

Path to the BBj program file to execute.

Config File

Optional config.bbx file to use for this program.

Working Dir

Optional alternate working directory to use for this program.

Run As User

Optional alternate user to use for executing the program.

Arguments

Optional list of program arguments.

Quiet

Runs the BBj interpreter quietly.

Terminal

The terminal specification.

Classpath

Session-Specific classpath (SSCP) to use for executing the program.

Run Now Button

Execute the program immediately for testing purposes.

Task Type - Execute System Call

Specifies a script or executable to run on the server by the operating system. The Command should specify the full path to the script or executable unless that item is located in the operating system’s executable “PATH”. The task completes when the executable or script completes successfully or returns an error.

Task Type - Pause/Resume A Replication Job

The pause task pauses the specified replication job to allow for a backup or similar script or program to perform some kind of operation on the affected files. A resume task resumes a paused replication job. Use the “Replication Job” drop down list to specify the replication job to pause or resume.


Scheduling Jobs Using the Enterprise Manager

The Scheduling panel displays a list of all currently configured scheduling jobs or “Task Groups” and provides an interface for creating, modifying and removing task groups. Each Task Group contains one or more tasks to be executed. The panel gives the administrator the ability to see the tasks within each group, when they will run next, and when last run.

Access the Scheduling panel by selecting the “Scheduling” item from the Enterprise Manager navigation area.


Task Group

Name of the Task Group.

Scheduling/Task Type

For Task Groups, displays a short description of the scheduling for the group including the start date and how it will repeat. For Tasks, shows the type of Task.

Next Run

The next time the Task Group is scheduled to run.

Last Run

The last time the Task Group executed.

Associated File

The script or program file that will be executed (for BBj and SCALL Tasks) or the replication job name (for Pause/Resume Replication Job Tasks).


Create Task - Scheduled or Autorun

  1. Click the “+” in the scheduling tab and the New Task Group Wizard will appear.


    Start a scheduled task.

    Pause a scheduled task.

    Add a new scheduled task.

    Delete a scheduled task.

    Refresh the task list.

  2. Enter the “Task Group Name".

  3. Select the type of task, “Scheduled” or “Autorun”.
    o  Scheduled - Groups of tasks that run at designated intervals
    o  Autorun - Group of tasks that will run one time when BBjServices is initially started

  4. Click Next >.

  5. Select the frequency when the task is to run by selecting the initial start time, end time.

  6. For Repeat Type, select None, By the Minute, Hourly, Daily, Weekly, Monthly, or Yearly.

  7. Select the frequency that the task will run.

  8. Click [Next >].

  9. Add tasks to the task group by clicking the “+.”

  10. Click the “+” in the task list panel to open the add task wizard.

  11. Select the task type.

  12. Select the program file for the task to run.

  13. Select the config to be used.

  14. Select the working directory.

  15. Select the user for the task to run as. (Only users account in EM can be used.)

  16. Enter any Arguments that are required by clicking the “+” or remove an entry by selecting the argument and clicking the red “X”.

  17. Enable/disable if the task should run in Quiet mode.

  18. Enter the terminal if necessary.

  19. Select the classpath to be used.

  20. Click [OK] or select the [Run Now] button.

  21. Click [Finish] or select one of the icons to the right.

    Add a new task

    Copy a task

    Delete a task

    Move a task up

    Move a task down

See Also

Java Settings

Log Files

Memory Usage

Processes

Servers

Settings