Enable printing responses in console

Hi, All

Is there a way to make Gatling print out responses it gets right out in console? It’s not enough to understand what went wrong geting back only statuses like “400 Bad Request”.

Thanx

Hi,

You can uncomment some lines in the logback file for that purpose, see : https://github.com/excilys/gatling/blob/master/gatling-bundle/src/main/assembly/assembly-structure/conf/logback.xml

cheers
Nicolas

Thanks for quick answer, Nicolas.

I just tried to do so, but unfortunatelly, it doesn’t show response body itself like the one I can get using something like REST console.

If you uncomment the proper logger in logback.xml like Nicolas suggested, you’ll log requests and responses, including their bodies. For sure.

When you say that you don’t see the response body, is it because you get a 400 status code? If so, of course you won’t get the expected body: your request just failed.

Thanks a lot. That’s exactly the case, I get error 400.

So the problem is with your request, not your response.