Is it possible after send request get a url from redirect to variable? e.g. I request for 192.168.1.30:8080/ and this link redirect me to 192.168.1.30:8080/token/123, can I get /token/123?
val scn = scenario(“Scenario Name”)
.exec(http(“Open”)
.get("/"))
By default, redirects occur automatically, and any checks are performed only at the last redirection (‘landing’) location, which will not have a ‘Location’ header in the response.
It seems you need to (globally) override this behaviour with disableFollowRedirect applied to your HTTP configuration ( ref. http://gatling.io/docs/current/cheat-sheet/ , HTTP Protocol / Options ), and handle redirections yourself. A temporary/local override would be nice, but there isn’t one.