jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nalin Makar <nalin.ma...@gmail.com>
Subject Re: Single Java Request and multiple Sample Results
Date Fri, 14 Dec 2012 17:13:26 GMT
Hi Sebb,

I think I was unclear about the fact that one needs to be logged in to do op1, op2 and op3.
So, I am not sure how I can have separate samples for login, op1, op2, op3 and logout and
still be able to share the logged in session. This could be done using HTTP requests, but
my question was specifically around using Java Sampler.

I figured on way of doing this would be to record sub-samples in JavaSampler and then:
1. Process the saved XML files outside of java (or using some Post-processor if possible)
2. Extend / Implement a new kind of Summary Report that works on sub-samples and not just
on parent samples.

Thoughts?

Thanks!
-nalin
 
On Dec 14, 2012, at 3:38 AM, sebb <sebbaz@gmail.com> wrote:

> On 14 December 2012 06:12, Nalin Makar <nalin.makar@gmail.com> wrote:
>> Just came across
>> public void addSubResult(SampleResult subResult)
>> in SampleResult javadocs. Will try and see if this is the right way to go about it.
>> 
>> If someone has any wise words around this use case, please do share.
> 
> I would suggest using separate samples for the login, op1, op2, op3 and logout.
> Then use Transaction Controller to combine the samples.
> 
> That would make it easier to change the operations, and fit in better
> with the normal JMeter way of doing things.
> 
>> Thanks,
>> Nalin
>> 
>> On Dec 13, 2012, at 9:29 PM, Nalin Makar <NALIN.MAKAR@GMAIL.COM> wrote:
>> 
>>> Hi,
>>> 
>>> I have searched extensively online and couldn't find a solution to my problem.
>>> 
>>> We have a pretty good functional/automated coverage for the product that we are
testing and I would like to reused that code to also run load/perf tests.
>>> 
>>> We figured we'll use JavaSampler and implement AbstractJavaSamplerClient. So,
in a Java Request we wanted to do the following operations:
>>> 
>>> 1. In setupTest() --> do login
>>> 2. In runTest() -->
>>> a. Do op1
>>> b. Do op2
>>> c. Do op3
>>> 3. In tearDownTest --> logout
>>> 
>>> As, runTest() only returns a single SampleResult, I can only use that to report
on the overall status of running op1, op2 and op3. But I was wondering if there was a way
to report separate SampleResults for each of the 3 operations (op[1-3]).
>>> 
>>> Has someone implemented something like this?
>>> 
>>> Thanks,
>>> Nalin
>> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
> For additional commands, e-mail: user-help@jmeter.apache.org
> 


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


Mime
View raw message