How to set counter in PUT request?


If you have a proper look at the documentation, you’ll see that you can’t pass Scala code in Gatling EL expressions.
There’s no way “${counter.get()}” could possibly work.
You’d have to pass a function to build your String, not use Gatling EL.

Thanks for the reply.
If possible can you please show any example how to implement this and pass that function to request?

This code works for me

exec(http("test") .get(session =>s"""${counter}""") )