headerRegex does not return value in 2.0.0-M3a

val httpConf = http
.acceptEncodingHeader(“gzip, deflate”)

val users = scenario(“Users”)
headerRegex(LOCATION, “.*”).findAll.saveAs(“redirectURL”)))
.exec(session => { println(session(“redirectURL”).as[Seq[String]]); session })


Works fine for me, prints ArrayBuffer(https://www.google.fr/?gws_rd=cr, ) as expected.
Maybe a typo somewhere

thank you for your attention, i managed to get it working by adding verification keyword “whatever”

.check( header(LOCATION).findAll.whatever.saveAs(“location”) )

and i get the same result as you do.
but how do i access elements of this array using EL? i need “https://www.google.fr/?gws_rd=cr” but not “ArrayBuffer(https://www.google.fr/?gws_rd=cr )”

Then why do you use findAll and not a regular find (which is an alias for find(0)?

In Gatling EL, if foo is the key for a Sequence, you can use ${foo(i)} to retrieve an element:


you are right, my bad.
thank you for your help!