Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Periodic job to run only after the predecessor completed

Former Member
0 Kudos

Hi All

I want to schedule a job which runs periodically every 30 min.But I have a constraint where in two jobs should not run parallelly.So if the first job runs more than 30 min then the second job will get effected.

So for this requirement, successive job should wait till the previous job finishes and start only after the previos one gets completed.

Is there any way I can schedule a periodic job like this?

Thanks

avinash

1 ACCEPTED SOLUTION

Mohamed_Mukhtar
Active Contributor
0 Kudos

Hi Avinash,

This may be achieved by creating a job with two steps . The approach can be like below :-

1. In step1 : Predecessor program

2. In step2 : Second program

You may use program RSBTONEJOB2 to schedule the job which has two steps. This program will make sure that only one active instance of that particular job is running.

Please go through the below link

Thanks

Always Learner

2 REPLIES 2

Mohamed_Mukhtar
Active Contributor
0 Kudos

Hi Avinash,

This may be achieved by creating a job with two steps . The approach can be like below :-

1. In step1 : Predecessor program

2. In step2 : Second program

You may use program RSBTONEJOB2 to schedule the job which has two steps. This program will make sure that only one active instance of that particular job is running.

Please go through the below link

Thanks

Always Learner

0 Kudos

Thanks Learner.

Modified  RSBTONEJOB2 as per my requirement and perfectly working.

Thanks

avinash