jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: Different string for each Loop
Date Wed, 10 Nov 2010 18:59:01 GMT
On 10 November 2010 18:51, Andrei Ghimus <ghimus@gmail.com> wrote:
> MyJavaSampler calls the test method "s2load.jmeter.SearchServer". Do
> you have s2load.jar in your lib/ext?

Yes.

SearchServer has the following method:

public void setupTest(JavaSamplerContext context)  {
    ...
    query = context.getParameter("query");
}

which is obviously why the query does not get updated.

> On Wed, Nov 10, 2010 at 7:47 PM, sebb <sebbaz@gmail.com> wrote:
>> On 10 November 2010 18:16, Andrei Ghimus <ghimus@gmail.com> wrote:
>>> I have uploaded all necessary files to
>>> http://ghimus.ro/jmeter-issue-1/
>>>
>>> My jar and all its dependencies are in extlibs.zip; unpack in
>>> "jakarta-jmeter-2.4/lib/ext/". My class needs GWT libs, which I have
>>> included, but they hurt JMeter on my machine. I needed to increase
>>> PermGen to 164MB for it to run with the GWT libs.
>>>
>>> My sampler will fail (connection refused), but it will report its
>>> 'query' parameter in ResponseMessage. There's also the stock Java
>>> Sampler JavaTest for a side-by-side comparison.
>>>
>>
>> I could not find the code for the MyJavaSampler.
>>
>> That is where the problem is likely to lie.
>>
>>>
>>>
>>> On Wed, Nov 10, 2010 at 6:47 PM, sebb <sebbaz@gmail.com> wrote:
>>>> On 10 November 2010 16:35, Andrei Ghimus <ghimus@gmail.com> wrote:
>>>>> On Wed, Nov 10, 2010 at 4:58 PM, sebb <sebbaz@gmail.com> wrote:
>>>>>> On 10 November 2010 14:31, Andrei Ghimus <ghimus@gmail.com>
wrote:
>>>>>>> Good day!
>>>>>>>
>>>>>>> I'm using JMeter to load test a search webapp.
>>>>>>> I have a Sampler in a 100x Loop that sends a search query to
the
>>>>>>> application and I need the search query to be different from
the
>>>>>>> previous one.
>>>>>>>
>>>>>>> What I've tried so far:
>>>>>>> - __StringFromFile() - does not work because it only moves to
the next
>>>>>>> line at the start of each Thread/Iterarion, not at the start
of each
>>>>>>> Loop,
>>>>>>
>>>>>> That's not the case.
>>>>>>
>>>>>> SFF does work; however it depends where you reference it - if it
is in
>>>>>> a Config element then the file will be read when the Config element
is
>>>>>> processed.
>>>>>>
>>>>>> If you reference it directly in the sampler, or in the UDV
>>>>>> Pre-Processor it will work as you want.
>>>>>
>>>>> If I reference it in the Sampler, it always returns the first line. If
>>>>> I put a User Parameters (I assume that's what you meant by UDV)
>>>>> pre-processor in front of it, it always returns the second line.
>>>>
>>>> Yes, I meant User Parameters.
>>>>
>>>> Remember that Pre-Processors are invoked before *every* sampler in
>>>> scope - there must be another sampler that is causing the first line
>>>> to be read.
>>>>
>>>>>>
>>>>>>> - __FileToString() - does not work because I can't __split()
the file
>>>>>>> by newline,
>>>>>>> - CSV Data Set Config - does not work, not even nested inside
the
>>>>>>> Loop, same as for __StringFromFile(),
>>>>>>> - __CSVRead() - does not work, same as for __StringFromFile().
>>>>>>>
>>>>>>> I'm running out of ideas/options. If anyone has done anything
similar,
>>>>>>> please share how you went about it.
>>>>>>>
>>>>>>> ---------------------------------------------------------------------
>>>>>>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>>>>>>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>>>>>>
>>>>>>>
>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>>>>>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>>>>>
>>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>>>>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>>>>
>>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>>>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>>>
>>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
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