I have a subprocess that I need to be executed daily during a week, monday to friday in a given hour of the day.
But it is only one specifc week.
I dont know the day it will start until I reach a certain human activiy.
I have tried many configurations but all have failed.
With a start timer (cron) I can put a decision to execute or not the tasks during the space time I want but the timer will run forever. Is that a problem on production?
Is there some kind of pattern for this kind of situation?
I have Bonita Studio Community 2.65 running on Java 6 on Ubuntu 13.10.
Hello,
If this happens only once a year, maybe you could have a different design for this specific need. Once you reach the human activity that should be the breaking point, after that you can use a call activity that will have a loop fixed to 5 occurencies (representing 5 days - Monday to Friday). In your subprocess, you could then have whatever you need and a timer of 24 hours just before the end. This means that each instance of the subprocess would take 24 hours (approximately), and you will assure to do it 5 times by using a loop on the call activity.
Would that help?
Haris
Well, I think it partially solves the problem. Because this I will not be able to set a fixed hour to the task to be executed.
Let me be more clear.
1 - Start the process and do some tasks
2 - At a given activity a user inputs a date
3 - The process continues with its flow
4 - Parallel to this another process must be initiated at the given date, repeat for five days, monday to friday at 9:00 AM
haris.subasic, in your suggestion I can not guarantee that parallel task will be executed always at 9:00 AM even using a delay timer, right?
Hello,
OK, I understand. You could always introduce another timer just before a call to the subprocess that would calculate a delay from that moment ‘until next Monday 9AM’ and guarantee a pause/delay until. That way you would start executing your subprocesses for the first time on Monday at 9AM and loop 5 times every 24 hours.
Hope this helps,
Haris
It worked!
Although I have tested it in a scale of minutes now I am secure to say that it will work.
Solution:
A parallel gateway forks to a delay timer that holds until the date to start the parallel sub-process.
A call activity is called recursively counting with variable through the Operations tab.
Before the path return recursively to the call activity there is another delay to the defined hour.
Thanks haris.subasic.
Great, happy to hear that we were able to help you