jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <>
Subject Re: Variable use in 'number of threads'?
Date Fri, 03 Jun 2005 23:29:41 GMT
On 6/3/05, Sander Stevens <> wrote:
> Hi Mike (and Sebb),
> OK, clear. I noticed that a user defined variable (rows   40) is working
> fine (${rows} is used in number of threads and my testplan is working
> fine with 40 threads). But I want to read this value from a file,
> because it differs every time (depending on the number of testcases).
> Today it will be 40, but tomorrow it will be 50 because 10 more
> testcases are added. And this value should be updated automatically in
> the number of threads.
> So I was trying to read the count of rows from my excel sheet and place
> that in number of threads. But obviously you can't use __CSVRead or
> __StringFromFile. If I use those functions, my testplan doesn't work
> anymore.

It works for me using 2.0.3 (and the latest nightly).

I set number of threads to the value:


where test.txt contains (e.g.):


I then added a JavaTest Sampler with the same CSV function call.

The result was 6 threads, and each read another line starting with line 2 = "a".

> So the number of threads is static the moment I start jmeter, but can be
> different the next time I start jmeter.

Which is what I thought originally.
> Any clues how to solve this?

See above.

Or omit the count from the CSV input file and pass the thread count in
as a property.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message