6 Replies Latest reply on Feb 28, 2018 9:13 AM by Michael Bobbato

    Control the sequence of cyclic jobs

    DevOps Progrexion

      I'm trying to create a POC of the following

       

      I've 3 cyclic jobs: jobA, jobB, jobC running each 1 minute.

       

      Each job has the following embedded script: sleep 30

       

      How can I do to get the following execution sequence: jobA - jobB - jobC - jobA - jobB - jobC .....

       

      Thanks.

        • 1. Re: Control the sequence of cyclic jobs
          Greg Tucker

          On JobC you would create an On-Do action that reorders the 3 jobs. Something like this;

           

          • 2. Re: Control the sequence of cyclic jobs
            DevOps Progrexion

            Hello Greg, thanks for your answer.

             

            Unfortunately the test didn't work. Only the first iteration was in the order expected. I've tried a lot of different ways without success.

            • 3. Re: Control the sequence of cyclic jobs
              Greg Tucker

              It worked for me over several iterations. Are JobB and JobC removing the prerequisite conditions? Also make sure you don't have any conditions left over from prior testing.

              • 4. Re: Control the sequence of cyclic jobs
                DevOps Progrexion

                I created everything from zero and this time it worked. Thank you very much.

                • 5. Re: Control the sequence of cyclic jobs
                  Marco Bellusci

                  Does someone verify the answers here? This looks like a "homemade" solution and it will cause the following.
                  Instead of having 3 jobs in AJF, which can run cyclic all minutes, you will have all minutes three new jobs in your AJF. Each orderd job counts on your licence and it needs also more ressources than if you would build a smartfolder with three cyclic jobs. Best thing would be to install the new Version 9.0.18 which have cyclic smart folders finally.

                   

                  But till then I would build one smartfolder with the three depending jobs and an cyclic interval of 1 minutes and give them all the same exclusive Q-Resource.

                  So only one job at the time can run. As BMC do not yet have cyclic folders, it can happen that the third job of a cyclic chain, is still running but the first job starts also his second run/intervall. (take also care of the cyclic intervall option "from end" or "from start", it makes a differance. what if third job runs over 61 seconds, should the first job then already start or does it have to wait for its intervall and that the third job finishes?)

                  • 6. Re: Control the sequence of cyclic jobs
                    Michael Bobbato

                    If you cannot install 9.0.18, you can also have a dummy non cyclic job as the 'kicker'. With the three jobs as cyclic, you would have conditions jobA to jobB, jobB to jobC, and jobC to jobA. The same condition from jobC to jobA would be an out condition in the dummy kicker job. It runs when you want the process to start and kicks off A, and it works like a proper cyclic chain. If you have a task based license I also don't recommend the order job approach.

                    1 of 1 people found this helpful