Siebel spawning multiple instances of RCR Job

We all have heard or worked on RCR Jobs (Recurring Jobs) in Siebel. To whom this is new I would suggest that they read the introduction post first.

Problem Statement::
We had an RCR job that had repeat interval set to 15 minutes.

image

Due to server issues it got terminated. So, to redeploy this RCR  I performed the usual steps

  1. Copy the current RCR Job record.
  2. Click on Submit Job.

After few minutes I went to Repeating Instance tab to check if everything is working correctly or not. To my utter surprise I found that instead of executing the workflow every 15 minutes, Siebel was executing the workflow every 10 seconds causing unnecessary execution of the workflow and overloading the workflow process manager.

image

Reason:
A good friend of mine Anshu Joshua helped me out the figure out the reason for this behavior. When We schedule a RCR there are two important fields

  • Scheduled Start: It is a date time field which determines from when the execution of the RCR should start
  • Repeat From:: This field can have 3 values which are as following
    • Scheduled Start: Repeat the instances from the value in the Scheduled Start Field.
    • Actual Start: Repeat the instances from the time this RCR has been deployed
    • End: I will try to explain the value through an example.
      Suppose you have deployed an RCR with repeat interval of 10 min and for some reason your workflow takes 15 minutes to complete. If you enter the value of Repeat From field as End then the next instance will be scheduled 10 min after the first instance finishes. In other cases (Actual Start and Scheduled Start) even if the first instances has not finished another instance will be triggered after 10 min. So, in case if you feel that you workflow could run over the repeat interval use this value.

Now, let me try to explain the reason with help of an example::

Let’s assume I deployed my first RCR on 1 JAN 9:00 AM and the problem occurred on 1 Feb 4:00 PM. When I copy and create a new the RCR record on 1st FEB 5:00 PM, the value in the scheduled Start fields get’s copied over 1 JAN 9:00 AM and the Repeat From field has value Scheduled Start.

This forces Siebel to start executing this task every 10 seconds in order to somehow makeup for the lost time. I don’t have the exact calculation Siebel performs but what I can say for sure “Siebel makes up some amount of time with every execution and will eventually after X number of executions it will start spawning jobs normally”. Now this X could be 1000 in case difference between Scheduled Time and Actual time is less and could be 10000 in case the difference is more.

Solution:

There are two things you can do::

1. Always create a new RCR Job and never copy an old RCR record.
2. Change the Repeat From value to “Actual Start” after copying the RCR and before submitting the RCR job.

From this experience I think either Siebel should have made ‘No Copy’ true for Scheduled Start date or kept the default value as “Actual Start” for Repeat From field.

What do you think??

5 Responses to Siebel spawning multiple instances of RCR Job

  1. Even I had faced similar issues and had done a research regarding this. In the bookshelf same is given with the following examples

    Repeat From field in RCR has three possible settings:

    ■ Scheduled Start: Starts the next iteration of the repeating
    component job after the interval period has elapsed, as calculated
    from the time indicated by the field Scheduled Start. For example, if
    the repeat interval is five minutes, the scheduled start time is 09:00,
    and the component job actually starts at 09:02, the next component
    job is scheduled to start at 09:05. Using this selection may result in
    a backlog of component jobs that will be started if the actual start
    time is later than the scheduled start time.

    ■ Actual Start: Starts the next iteration of the repeating component
    job after the interval period has elapsed, as calculated from the time
    the component job is started rather than the time indicated by the
    Scheduled start field. For example, if the repeat interval is five
    minutes, the scheduled start time is 09:00, and the component job
    actually starts at 09:02, the next component job is scheduled to start
    at 09:07.

    ■ End: Starts the next iteration of the repeating component job after
    the previous component job ends and the repeat interval has
    elapsed. For example, if the repeat interval is five minutes, the
    scheduled start time is 09:00, the component job starts at 09:02,
    and then the first component job ends at 09:04, the next component
    job is scheduled to start at 09:09.

    Regards

    Premjit M Vidyadharan

    • Thanks for the information Premjit… It seems it was information always there in bookshelf and we just never looked at it and learned it the hard way.

      But still they keeping default value as Scheduled start for “Repeat From” field doesn’t make any sense and leads to this unnecessary issue…..

      • Yes you are correct. A field of such significance should be made mandatory without any predefault value so that people realize the importance and functionality driven from the values:)

  2. Hi guys, regarding the following sentence “In other cases (Actual Start and Scheduled Start) even if the first instances has not finished another instance will be triggered after 10 min.” I have a different experience: if the first instance has not finished yet, the second one is put in queue and it will start as soon the first instance will terminate. Has everyone ever had the same behaviour?

  3. Hello, I have one question. When I created a job to execute a workflow each day,  it starts at the moment I submit it, it doesn’t listen to the scheduled start. Do you have any idea of the reason of this behaviour?

Leave a Reply

Contribute