JMeter keeps track of the number of active threads

The methods

ThreadGroup.getNumberOfThreads()
and
JMeterContextService.getNumberOfThreads()

can be used to obtain this at run-time.

However, this number is incremented as soon as the thread starts, i.e.
before any start-up delay. It is decremented when the thread ends.

I don't think one can easily determine at present when the threads
have completed the start-up delay - perhaps it would make more sense
if the thread count were incremented after the delay.

However, even if the count only applied to threads processing a test,
this would not tell the whole story, as the activity at the server
depends very much on what the test plan is actually doing; in
particular, what Timers are included.

All one could say is how many other threads are potentially doing
something at the same time.

It might be possible to keep track of the number of "open" samples -
i.e. samples that have been started and not finished, but this would
have to be carefully implemented to avoid creating a bottle-neck.

==

Come to think of it - the log file already has this information, as
every sample has a duration and a start or end-time.

Extracting this information would not be trivial, but it should not be
too difficult either.

S.
On 22/02/06, Pavel Gouchtchine <[EMAIL PROTECTED]> wrote:
> I am doing performace test with different combination of thread per
> second to hit the server.
> I see all threads started at the same moment, and I cannot say during
> the test how many threads now are hitting the server, other words, how
> many threads are actually started, running, finished, created and
> waiting.
>
> Pavel
>
> On 2/22/06, Pavel Gouchtchine <[EMAIL PROTECTED]> wrote:
> > The tool shows the same as the task manager: number of created threads.
> > I am looking for number of started and running threads.
> >
> > Pavel
> >
> > On 2/22/06, Pavel Gouchtchine <[EMAIL PROTECTED]> wrote:
> > > Thanks a lot.
> > > For Windows XP there is  Service Pack 2 Support Tools that includes
> > > this tool and many others for monitoring the system.
> > > Pavel
> > >
> > > On 2/22/06, Lincoln, Adym <[EMAIL PROTECTED]> wrote:
> > > > Pavel,
> > > >
> > > > There use to be a simple Windows program call pmon.exe, short for
> > > > process monitor.  I just tried it on my Windows 2000 Professional and
> > > > couldn't find it.  I use to use it on Windows 95/NT many moons ago when
> > > > I was doing Windows/M$ development, but I've since fallen behind with
> > > > regards to Windows/Visual Studio development.
> > > >
> > > > Bottom line, pmon.exe is probably still around and it should give you a
> > > > clearer picture of processes on your Windows box then Task Manager...
> > > >
> > > > hth,
> > > >
> > > >
> > > >
> > > > Adym Lincoln
> > > > I/S Corporate - I/S Internal Applications
> > > > 603-245-8245
> > > > Ext : 58245
> > > > [EMAIL PROTECTED]
> > > >
> > > > ...
> > > > It's a bug planet...it's an ugly planet...ever feel like your software
> > > > project is going in the wrong direction.
> > > > ...
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: Pavel Gouchtchine [mailto:[EMAIL PROTECTED]
> > > > Sent: Wednesday, February 22, 2006 12:43 PM
> > > > To: JMeter Users List
> > > > Subject: Re: Thread number and Ramp-up time relationship?
> > > >
> > > > Thank you for the question.
> > > > The threads just start at once. It is  true. Now I understand it.
> > > > And I don't know how to monitor the number of started (running) threads.
> > > > Does any body know? Please, give an advise.
> > > >
> > > > Pavel
> > > >
> > > >
> > > > On 2/22/06, sebb <[EMAIL PROTECTED]> wrote:
> > > > >
> > > > > But do the threads *start* earlier than expected, or is it just that
> > > > > the threads are created all at once?
> > > > >
> > > > > S.
> > > > > On 22/02/06, Pavel Gouchtchine <[EMAIL PROTECTED]> wrote:
> > > > > > Hi All.
> > > > > > I am using JMeter 2.1.1 on Windows XP.
> > > > > >
> > > > > > According JMeter documentation:
> > > > > > " The ramp-up period tells JMeter how long to take to "ramp-up" to
> > > > the
> > > > > full
> > > > > > number of threads chosen. If 10 threads are used, and the ramp-up
> > > > period
> > > > > is
> > > > > > 100 seconds, then JMeter will take 100 seconds to get all 10 threads
> > > > up
> > > > > and
> > > > > > running. Each thread will start 10 (100/10) seconds after the
> > > > previous
> > > > > > thread was begun. If there are 30 threads and a ramp-up period of
> > > > 120
> > > > > > seconds, then each successive thread will be delayed by 4 seconds."
> > > > > >
> > > > > > I have started to monitor number of threads using Task Manager and I
> > > > see
> > > > > > that all threads starts at once, and  ramp-up time doesn't play any
> > > > role
> > > > > > here.
> > > > > > For example, when I have Number of Threads: 1000 and Ramp up time 60
> > > > > sec, I
> > > > > > am expecting to get all 1000 threads up and running only in 60 sec.
> > > > > That  I
> > > > > > see is different: all 1000 threads started at once.
> > > > > >
> > > > > > Is it something, that I am missing in configuration or it is a
> > > > problem?
> > > > > >
> > > > > > Thank you.
> > > > > > Pavel Gouchtchine
> > > > > >
> > > > > >
> > > > >
> > > > > ---------------------------------------------------------------------
> > > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > > >
> > > > >
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > >
> > > >
> > >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to