Request does not receive response body

I’m trying to access the webpage and cannot seem to receive response body.

Beware that, as an optimization, Gatling doesn’t pile up response chunks unless a check is defined on the response body.

But even when i’m using checks (such as .check(bodyString.saveAs(“RESPONSE_DATA”))) the response is not coming through. I’m trying as simple as visit the main page of website with all according headers to no avail.

Is there something i’m missing?

Please provide a way to reproduce your problem.
Otherwise, we would just be wasting time, playing riddles.

Ok, i’m trying to run something like that:

import io.gatling.core.Predef._
import io.gatling.http.Predef._

class Test1Simulation extends Simulation {

  val httpProtocol = http
    .baseUrl("https://gatling.io")

val scn = scenario("TestSimulation")
  .exec(
    http("Test page")
      .get("/docs/current/")
      .check(bodyString.saveAs("RESPONSE_DATA"))
      .check(status.is(200))
    )

setUp(scn.inject(atOnceUsers(1))).protocols(httpProtocol)
}

I’m using Intellij IDEA Community 2019.2.4 with the latest maven archetype. The logging is set to DEBUG. And i expect to get response body in log file to extract and re-use values, however the response body is just not there. Attached the gatling.log file to show that there is no response body as well as RESPONSE_DATA variable is missing.

I’m also wondering why there is “content=null” always in log file.

I am very grateful for your attention.

gatling.log (33.7 KB)

The logging is set to DEBUG.

https://github.com/gatling/gatling/blob/master/gatling-core/src/main/resources/logback.dummy#L11-L13

Attached the gatling.log file to show that there is no response body as well as RESPONSE_DATA variable is missing.

Wrong, RESPONSE_DATA is here but you don’t log it.

I’m also wondering why there is “content=null” always in log file.

Because this internal DEBUG log you’re mentioning is not response body.

I am terribly sorry for wasting your time, but somehow i really missed the logback configuration, and TRACE is doing exactly what i want. I utterly appreciate your impact on my Gatling endeavors. Thank you so much!

Glad it works for you!
Sorry if my answers are very hasty, I’m super swamped atm :stuck_out_tongue: