jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: How to extract "Body size in bytes" from the http sampler result.
Date Tue, 01 Oct 2013 22:11:01 GMT
On 1 October 2013 19:49, Flavio Cysne <flaviocysne@gmail.com> wrote:
> Use Beanshell Post-Processor, inside the sample you want its body length,
> with the code below:
>
> response = prev.getResponseDataAsString();
> data_length = new Integer(response.length());
> vars.put("data_length", data_length.toString());

Or just use:

data_length = prev.getBytes();

> Then, you can use ${data_length} variable as desired.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
For additional commands, e-mail: user-help@jmeter.apache.org


Mime
View raw message