Parallel executions within one scenario

Hi there again,

I was wondering if it is possible to have some parallel executions ongoing within one scenario that models my user application. The application refreshes its UI at regular intervals in the background. Additionally, I have the “ordinary” interaction of the user with the application that results in requests.

ATM I model this using a timer that is stored in the session and I check if this background refresh has to be done and reset the timer. However, this is not that accurate and a little bit cumbersome to program.

I was thinking of an approach similar to Java’s ScheduledExecutorService where you pass some code that executes this background refresh thing and is executed at a given rate / intervals.


Trying to model this will be cumbersome. As you guessed, you are going to have to keep track of the last time you did the background refresh, and then in your main processing loop, see first if it is time for the background refresh. If so, do that, if not, do your user interaction. Making that work will force you to be careful how you model your user interactions. If you do not model it as a loop, it’s going to be very difficult, if not impossible.