Dynamic Think Time

Hi Everyone,

Im trying to simulate a service that would be sending out empty "attachments" simulating the live system (where it sends actual attachments with varying sizes) and would like to simulate dynamic ThinkTimes

For example,
1. 2 documents, it should send out the response after 2 secs
2. 6 documents, it should send out the response after 13 secs


We are using Virtualize 9.10.1


  • Ireneusz SzmigielIreneusz Szmigiel Posts: 220 ✭✭✭

    Hi lukeliwang

    see section "Controlling Performance Profiles and Data Groups" in help/user manual.
    As you can see on screen shot there is a few different options which you can use.

  • lukeliwanaglukeliwanag Posts: 36

    hi @Ireneusz Szmigiel thanks for your response. I read through it and it is helpful. however i forgot to mention, the response think time will base off of the request.

    Basically the request will tell virtualize how many documents it's expecting.

  • benken_parasoftbenken_parasoft Posts: 1,025 ✭✭✭

    I'd like to comment on "dynamic think times". Aside from "Performance Profiles", the responder also has a "Think time" field on the "Options" tab under "Performance". You can configure this other think time field to be parameterized or scripted.

    You could consider taking a data driven approach, where both the response values and think time are being pulled from a data source. You could configure your responder to use data source correlation, where the response values and think time could be parameterized, using values from a particular data source row that correlated with the incoming request.

    Another approach is using scripting and extractions. You can use a Data Bank to extract any values you need from the incoming request to calculate the desired think time. Next, if you script the "Think time" field, then your script will take a single argument of type com.parasoft.api.ScriptingContext. You can access Data Bank columns by calling context.getValue("Generated Data Source", "name_of_your_data_bank_column") where "context" is the ScriptingContext argument to your script.

Sign In or Register to comment.