ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Job with DLYJOB missed RSMTIME

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Job with DLYJOB missed RSMTIME

    I have a job that runs every fifteen minutes. This is done by using the DLYJOB RSMTIME(hhmmss) where the time is computed after every run. The job was supposed to run at 131500 but due to an error the job only got released on 131527. Having missed the scheduled time the job will now wait for 131500 on the next day. Is there any way we could change the RSMTIME so that the job runs today instead of tomorrow?

  • #2
    I am not aware of any way of doing this. Unless you do something silly like roll your system time forward a day it will wait until the time specified.
    I would suggest changing your program to check if the time has passed and then make a decision on whether to run the process immediately or wait until the next interval.

    Comment


    • #3
      The only way I know of is if you add it to the job schedule (ADDJOBSCDE) specifying RCYACN. To submit the next one issue a RMVJOBSCDE to remove the current one and an ADDJOBSCDE to insert a new one specifying the new date & time that is 15 minutes after current one.

      Comment


      • #4
        Alternatively, you could create a job that has a continous loop that has a DLYJOB DLY(900) - executes what you want. Since it's a loop it will delay 15 minutes, execute the code, etc. You can then put this as an auto start job in a subsystem. That way if you had to reboot the system the job will start up by virtue of the subsystem starting.

        Comment


        • #5
          The latter is, in my mind, preferable. You only have the overhead of starting the job once....

          Comment

          Working...
          X