How to dynamically generate JSon in Gatling?
问题 I have the following two methods: def randomStartMethod() : Long = { var range = 1000L var r = ThreadLocalRandom.current().nextLong(10L*range) var randomStart = 1396024675000L + r return randomStart } def randomStopMethod() : Long = { var range = 1000L val r = ThreadLocalRandom.current().nextLong(10L*range) val randomStop = 1396024675000L + r*2L return randomStop } Then I add it to the request body like this: val activity = repeat(10, "i") { exec(http("POST activity post") .post("/activity/")