Community forum

Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


thomas
2015-06-29T11:50:49Z
Hi

I am trying to achieve the following, but have failed miserably:

I have a job with several tasks, and I would like to run all of them asyncronously for maximum performance . Once ALL tasks have completed I would like to send an e-mail. For those who are familiar with Javascript, it would be similar to Promises (or Deferred in JQuery).

I tried setting up a testjob with two tasks. The first on sleeps for 25 seconds and runs async. The next sleeps for 10 seconds and also runs async. At the job level I set 'on success' => send an email. This does not work as the email is fired as soon as the last task starts. In javascript I could write (pseudo code):

Sleep 25 secs async
Sleep 10 secs async
When all have completed, send email.

Can this be done in VC?

Edit: I see now that I can try unchecking 'Run tasks in order' at the job level. But what If I need to run the first task syncronously, and all the following tasks async?

Thomas
Sponsor
Forum information
Support
2015-06-29T16:16:19Z
Right now you cannot mix asynchrous and synchronous within a Job. If you need that you can use Job/Task control Task and separate Tasks in a second Job.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Scroll to Top