04-19-2017 02:16 AM
I would like to sychronize paralell sequencenes without a Batch process model. We use a custom process model so I couldn't use the Batch test types. As in my example, I call threetimes the same sequence paralell. In our test bench I used to synchronize Rendezous test steps. But sometimes it seems that the Rendezous step will not be handled correctly an the main sequence is waiting at the Rendezous step although the paralell sequences might be finished.
Are there any other way to synchronize the paralell sequences without Batch process model. I tried also Batch Specification test step but I don't know how to use it exactly.
Thanks
Stefan
Solved! Go to Solution.
04-19-2017 04:21 AM
Hi Stefan,
The Batch Specification step is what will create the same conditions you get with the Batch Process Model (you can use the batch synchronization steps). I've attached a modified version of the example you put up, using this method to force the main sequence to wait for all created threads to finish.
Some points:
1. The batch is first created, and you can populate it with threads as they are started in each sequence call.
2. In each sub_seq call a thread is added to the batch, this requires you storing an object reference for each of the threads when selecting to open it in a new thread.
3. Checking the batch for any threads still running can be used to halt the main sequence until all sub_seq calls have completed.
I hope this helps.
04-19-2017 06:57 AM
great, it works.
That's what I'm looking for and thank you for your example which is very helpful for understanding the test step.
BR
stefan
04-19-2017 07:55 AM