I'm getting stuck in this scenario. For example I have 3 scenarios A, B and C. The scn A will generate a required value for B and C. So scn B and C will be executed in parallel but after scn A completed.
I'm using andThen() function, that is introduced in Gatling 3.4 but it seems I couldn't access session variable of scn A from B and C.
setUp(
A.inject(rampUsers(numReporters) during userCountRampUpTime)
.andThen(
B.inject(rampUsers(numBrowsers) during userCountRampUpTime),
C.inject(rampUsers(numSearchers) during userCountRampUpTime)
)
) .protocols(httpProtocol) .assertions( forAll.successfulRequests.percent.gt(95), forAll.responseTime.max.lt(respTime) )
A Session is the memory space associated to a given virtual user. Scenarios execute different virtual users sets. There's no way your implementation would work.
Then, you have described your actual issue, only your implementation tentative.
If you're trying to share data between scenarios, use something like a ConcurrentHashmap.