Flavio, thanks for responding here and in a second mail. Sorry, my Test
Plan is very large, and quite complicated. I tried to simplify it by
omitting anything I believed to be unnecessary (which I depict with
ellipses), but evidently what I posted wasn't clear.
1) The essence of Test Fragment XYZ is:
- Test Fragment XYZ
-- CSV Data
...
-- RegExp Extractor ( refName: 'Fields' )
...
-- If Controller ( condition: "${Fields_matchNr}"!="0" )
--- BeanShell Sampler #1
--- Loop Controller ( count: ${Fields_matchNr} )
---- BeanShell Sampler #2
---- Counter ( start: 1, max: ${Fields_matchNr} )
---- BeanShell Sampler #3
---- HTTP Request
---- BeanShell Sampler #4
--- BeanShell Sampler #5
...
2) This Test Fragment is referenced by a Module Controller as the only item
of a Thread Group. (This structure might be odd, but there's a reason for
it, too long-winded to detail here).
3) The 'Fields' array stems from a Regular Expression Extractor before the
If Controller in the Fragment (now shown above).
4) I used five BeanShell Samplers to show what part of the Fragment is
executed, and to print ${Fields_matchNr} - it contains the correct/expected
number in each case (please see the logs in the original post).
5) The data drawn from the CSV is as expected.
To stress: this Fragment works fine when the Thread Group has N threads and
a Thread Group loop count (ie. iteration count) of one: I've called this
'concurrent execution' of N users.
However, when I specify one thread and N iterations for that thread (which
I've called 'sequential execution' of the same N users), the Loop Controller
of the Fragment is executed only for the first iteration, but not for
iterations 2..N.
I don't know why, and it's a bit of a show-stopper for me.
Nige
-----Original Message-----
From: Flavio Cysne [mailto:[email protected]]
Sent: Friday, 15 May 2015 8:26 PM
To: JMeter Users List
Subject: Re: Loop controller behaviour
Nige,
what`s inside TestFragment XYZ? Is there any relationship betweeen this
fragment and the Test Plan presented?
Where in the script is Fields_matchNr initialized?
I suggest you to "print" the ${Fields_matchNr} value to check if it has
an unexpected content.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]