jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kristof Jozsa <...@ond.vein.hu>
Subject Re: uploading files in jmeter
Date Mon, 30 Jun 2008 11:19:46 GMT
sebb wrote:
>>  I plan to run the test with around 100 concurrent users, so that means 100
>> different files down- and then uploaded, but as I saw JMeter generates those
>> filenames.. Is it possible to use a beanshell postprocessor to save the
>> generated filename to a variable?
>>
> 
> The filename is stored in the SampleResult, and can be obtained as follows:
> 
> sampleResult.getResultFileName()
> 
> So you can add a BeanShell Listener with the script:
> 
> vars.put("FILENAME",sampleResult.getResultFileName());
> 
> Note that the Save Response element is actually processed as a
> Listener, not a Post Processor, so you must use a Listener to extract
> the value. [This is very confusing, so it needs to be fixed...]

I thought it's not too confusing but seems I didn't get it then. I have 
a HTTP Request sampler which has two post processors: the 'save 
responses to a file' item and a beanshell script trying to set the 
FILENAME variable, but appearently the sampleResult is null here. I 
should add the Beanshell postprocessor to the Save Response element? How 
can I do that?

Kristof


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


Mime
View raw message