How can I get the size of response of any API in gatling HTML report?

Is there any way of getting the response size in Gatling HTML report?
Like some setting in gatling.conf file that a user can enable.

Exactly what are you trying to accomplish?

I also have this requirement.
I have a few REST endpoints that response different sized JSON objects, so I want to see what’s the throughout of each endpoint in terms of bytes per second and the total throughput (in Kb/s or Mb/s probably)

Do we have any way in Gatling that we enable this kind of measure?

Kind regards,

-Pujitha.

Hi there,

No, such metric is not available.
The only similar thing you can have is bandwidth usage per remote host on FrontLine.

Note that depending on what you want and do exactly, JSON payload size can be very different from actually wire size because of gzip compression and TLS encryption.

Regards,

If every time you call some endpoint X, if there is no control over the size of the JSON response, then what statistical value is there to looking at the data? (Hint: there will be next to none, which is why there is no such stat available in Gatling.)

However, if you can control the request so as to result in a fixed size response, then you can measure the throughput of that one request, and get some meaningful measurements. That is, if you are only measuring the network and don’t care about the time required to service the request. And so long as you don’t mix varying sizes, as you lose all statistical meaning as soon as you do that.

As with everything in load testing, how you get from here to there depends on exactly where “there” is. You have to ask the right question, and be certain that you can answer that question by doing what you want to do. So, back to your original question: You want to measure the response size. Exactly WHY do you want to measure the response size? What is the question that was being asked of you that led you down this path in the first place?

Sorry to bother you John but don’t take me wrong. Actually I am new to Gatling so just hopping from one task to another as per requirement. So in my regression report which contains the failure API endpoints, my team wants the API response sizes as well as we can see in the chrome developer tool NETWORK tab. I was just wondering about its feasibility or we can show the data count on which the test has run in HTML report like or something. May be for that we have to purchase the enterprise one.