JMeter Query on Threads

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|

JMeter Query on Threads

Anil Kumar
Hi

Is there a way to add thread group with in a thread group ?

I have a scenario where a thread needs to run multiple threads, say kind of
forking..

regards
Anil
Reply | Threaded
Open this post in threaded view
|

RE: JMeter Query on Threads

indu
Hi Anil,

You Can simply follow below steps:

1) Add a new thread group per your need basis.
2) Select all the elements of the thread group -> copy them.
3) Now right click the new thread group and click paste, your all the elements will come inside this new thread group.
4) Now you can delete or Disable the old thread group and continue the execution with new thread group.

Regards,
Indu Gupta

-----Original Message-----
From: Anil Kumar [mailto:[hidden email]]
Sent: Friday, February 22, 2019 11:04
To: [hidden email]
Subject: JMeter Query on Threads

Hi

Is there a way to add thread group with in a thread group ?

I have a scenario where a thread needs to run multiple threads, say kind of forking..

regards
Anil

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

Anil Kumar
thank you for quick response,

i am trying here

Step 1 :start Thread Group 1
                 Step 1a: Create a  Login Session
                 Step 1b: start Thread Group 2
                                Step 1b1: Create a  User Session 1
                                Step 1b2: Create a  User Session 2
                 Step 1c: exit Thread Group 2
Step 2: exit Thread Group 1

Is this possible? assume which you mentioned above is different.



On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <[hidden email]>
wrote:

> Hi Anil,
>
> You Can simply follow below steps:
>
> 1) Add a new thread group per your need basis.
> 2) Select all the elements of the thread group -> copy them.
> 3) Now right click the new thread group and click paste, your all the
> elements will come inside this new thread group.
> 4) Now you can delete or Disable the old thread group and continue the
> execution with new thread group.
>
> Regards,
> Indu Gupta
>
> -----Original Message-----
> From: Anil Kumar [mailto:[hidden email]]
> Sent: Friday, February 22, 2019 11:04
> To: [hidden email]
> Subject: JMeter Query on Threads
>
> Hi
>
> Is there a way to add thread group with in a thread group ?
>
> I have a scenario where a thread needs to run multiple threads, say kind
> of forking..
>
> regards
> Anil
>
Reply | Threaded
Open this post in threaded view
|

RE: JMeter Query on Threads

indu
Hi Anil,

You can add "Loop Controller" within Thread Group  (Right click Thread Group -> Logic Controller -> Loop Controller).
Set number of Loop Count as "2" for 2 user sessions.

The test plan structure will look like:

Thread Group
    -Login Request
   - Loop Controller
        - User sessions

It will run 1 cycle of test like : 1 login request then 2 user session.

Hope your query is resolved now.


Regards,
Indu Gupta


-----Original Message-----
From: Anil Kumar [mailto:[hidden email]]
Sent: Friday, February 22, 2019 12:18
To: JMeter Users List <[hidden email]>
Cc: Naveen Nandwani <[hidden email]>; Sanjeev Anand <[hidden email]>
Subject: Re: JMeter Query on Threads

thank you for quick response,

i am trying here

Step 1 :start Thread Group 1
                 Step 1a: Create a  Login Session
                 Step 1b: start Thread Group 2
                                Step 1b1: Create a  User Session 1
                                Step 1b2: Create a  User Session 2
                 Step 1c: exit Thread Group 2 Step 2: exit Thread Group 1

Is this possible? assume which you mentioned above is different.



On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <[hidden email]>
wrote:

> Hi Anil,
>
> You Can simply follow below steps:
>
> 1) Add a new thread group per your need basis.
> 2) Select all the elements of the thread group -> copy them.
> 3) Now right click the new thread group and click paste, your all the
> elements will come inside this new thread group.
> 4) Now you can delete or Disable the old thread group and continue the
> execution with new thread group.
>
> Regards,
> Indu Gupta
>
> -----Original Message-----
> From: Anil Kumar [mailto:[hidden email]]
> Sent: Friday, February 22, 2019 11:04
> To: [hidden email]
> Subject: JMeter Query on Threads
>
> Hi
>
> Is there a way to add thread group with in a thread group ?
>
> I have a scenario where a thread needs to run multiple threads, say
> kind of forking..
>
> regards
> Anil
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

Anil Kumar
Hi Indu,

Thank you for taking you time...

We have consider your scenario, but loop controller had a limitation of
exec samples sequentially.
We rather looking for a solution which pump load concurrently (i.e., the
reason we are looking for an option of forking / threads ).

Warm Regards
Anil

On Fri, Feb 22, 2019 at 7:45 PM Indu Gupta <[hidden email]> wrote:

> Hi Anil,
>
> You can add "Loop Controller" within Thread Group  (Right click Thread
> Group -> Logic Controller -> Loop Controller).
> Set number of Loop Count as "2" for 2 user sessions.
>
> The test plan structure will look like:
>
> Thread Group
>     -Login Request
>    - Loop Controller
>         - User sessions
>
> It will run 1 cycle of test like : 1 login request then 2 user session.
>
> Hope your query is resolved now.
>
>
> Regards,
> Indu Gupta
>
>
> -----Original Message-----
> From: Anil Kumar [mailto:[hidden email]]
> Sent: Friday, February 22, 2019 12:18
> To: JMeter Users List <[hidden email]>
> Cc: Naveen Nandwani <[hidden email]>; Sanjeev Anand <
> [hidden email]>
> Subject: Re: JMeter Query on Threads
>
> thank you for quick response,
>
> i am trying here
>
> Step 1 :start Thread Group 1
>                  Step 1a: Create a  Login Session
>                  Step 1b: start Thread Group 2
>                                 Step 1b1: Create a  User Session 1
>                                 Step 1b2: Create a  User Session 2
>                  Step 1c: exit Thread Group 2 Step 2: exit Thread Group 1
>
> Is this possible? assume which you mentioned above is different.
>
>
>
> On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <[hidden email]>
> wrote:
>
> > Hi Anil,
> >
> > You Can simply follow below steps:
> >
> > 1) Add a new thread group per your need basis.
> > 2) Select all the elements of the thread group -> copy them.
> > 3) Now right click the new thread group and click paste, your all the
> > elements will come inside this new thread group.
> > 4) Now you can delete or Disable the old thread group and continue the
> > execution with new thread group.
> >
> > Regards,
> > Indu Gupta
> >
> > -----Original Message-----
> > From: Anil Kumar [mailto:[hidden email]]
> > Sent: Friday, February 22, 2019 11:04
> > To: [hidden email]
> > Subject: JMeter Query on Threads
> >
> > Hi
> >
> > Is there a way to add thread group with in a thread group ?
> >
> > I have a scenario where a thread needs to run multiple threads, say
> > kind of forking..
> >
> > regards
> > Anil
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

sebb-2-2
Can't you just increase the number of threads in the thread group?

On Fri, 22 Feb 2019 at 14:47, Anil Kumar <[hidden email]> wrote:

>
> Hi Indu,
>
> Thank you for taking you time...
>
> We have consider your scenario, but loop controller had a limitation of
> exec samples sequentially.
> We rather looking for a solution which pump load concurrently (i.e., the
> reason we are looking for an option of forking / threads ).
>
> Warm Regards
> Anil
>
> On Fri, Feb 22, 2019 at 7:45 PM Indu Gupta <[hidden email]> wrote:
>
> > Hi Anil,
> >
> > You can add "Loop Controller" within Thread Group  (Right click Thread
> > Group -> Logic Controller -> Loop Controller).
> > Set number of Loop Count as "2" for 2 user sessions.
> >
> > The test plan structure will look like:
> >
> > Thread Group
> >     -Login Request
> >    - Loop Controller
> >         - User sessions
> >
> > It will run 1 cycle of test like : 1 login request then 2 user session.
> >
> > Hope your query is resolved now.
> >
> >
> > Regards,
> > Indu Gupta
> >
> >
> > -----Original Message-----
> > From: Anil Kumar [mailto:[hidden email]]
> > Sent: Friday, February 22, 2019 12:18
> > To: JMeter Users List <[hidden email]>
> > Cc: Naveen Nandwani <[hidden email]>; Sanjeev Anand <
> > [hidden email]>
> > Subject: Re: JMeter Query on Threads
> >
> > thank you for quick response,
> >
> > i am trying here
> >
> > Step 1 :start Thread Group 1
> >                  Step 1a: Create a  Login Session
> >                  Step 1b: start Thread Group 2
> >                                 Step 1b1: Create a  User Session 1
> >                                 Step 1b2: Create a  User Session 2
> >                  Step 1c: exit Thread Group 2 Step 2: exit Thread Group 1
> >
> > Is this possible? assume which you mentioned above is different.
> >
> >
> >
> > On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <[hidden email]>
> > wrote:
> >
> > > Hi Anil,
> > >
> > > You Can simply follow below steps:
> > >
> > > 1) Add a new thread group per your need basis.
> > > 2) Select all the elements of the thread group -> copy them.
> > > 3) Now right click the new thread group and click paste, your all the
> > > elements will come inside this new thread group.
> > > 4) Now you can delete or Disable the old thread group and continue the
> > > execution with new thread group.
> > >
> > > Regards,
> > > Indu Gupta
> > >
> > > -----Original Message-----
> > > From: Anil Kumar [mailto:[hidden email]]
> > > Sent: Friday, February 22, 2019 11:04
> > > To: [hidden email]
> > > Subject: JMeter Query on Threads
> > >
> > > Hi
> > >
> > > Is there a way to add thread group with in a thread group ?
> > >
> > > I have a scenario where a thread needs to run multiple threads, say
> > > kind of forking..
> > >
> > > regards
> > > Anil
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

Anil Kumar
No, we cannot. If we increase,  each thread starts invoking Step 1a:
(above)  and consuming all licenses and also exhausting other resources.
Ex: Step 1a:  should invoke once and later Step 1b1/Step 1b2: shoud invoke
concurrently..





On Fri, Feb 22, 2019 at 8:48 PM sebb <[hidden email]> wrote:

> Can't you just increase the number of threads in the thread group?
>
> On Fri, 22 Feb 2019 at 14:47, Anil Kumar <[hidden email]> wrote:
> >
> > Hi Indu,
> >
> > Thank you for taking you time...
> >
> > We have consider your scenario, but loop controller had a limitation of
> > exec samples sequentially.
> > We rather looking for a solution which pump load concurrently (i.e., the
> > reason we are looking for an option of forking / threads ).
> >
> > Warm Regards
> > Anil
> >
> > On Fri, Feb 22, 2019 at 7:45 PM Indu Gupta <[hidden email]>
> wrote:
> >
> > > Hi Anil,
> > >
> > > You can add "Loop Controller" within Thread Group  (Right click Thread
> > > Group -> Logic Controller -> Loop Controller).
> > > Set number of Loop Count as "2" for 2 user sessions.
> > >
> > > The test plan structure will look like:
> > >
> > > Thread Group
> > >     -Login Request
> > >    - Loop Controller
> > >         - User sessions
> > >
> > > It will run 1 cycle of test like : 1 login request then 2 user session.
> > >
> > > Hope your query is resolved now.
> > >
> > >
> > > Regards,
> > > Indu Gupta
> > >
> > >
> > > -----Original Message-----
> > > From: Anil Kumar [mailto:[hidden email]]
> > > Sent: Friday, February 22, 2019 12:18
> > > To: JMeter Users List <[hidden email]>
> > > Cc: Naveen Nandwani <[hidden email]>; Sanjeev Anand <
> > > [hidden email]>
> > > Subject: Re: JMeter Query on Threads
> > >
> > > thank you for quick response,
> > >
> > > i am trying here
> > >
> > > Step 1 :start Thread Group 1
> > >                  Step 1a: Create a  Login Session
> > >                  Step 1b: start Thread Group 2
> > >                                 Step 1b1: Create a  User Session 1
> > >                                 Step 1b2: Create a  User Session 2
> > >                  Step 1c: exit Thread Group 2 Step 2: exit Thread
> Group 1
> > >
> > > Is this possible? assume which you mentioned above is different.
> > >
> > >
> > >
> > > On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <[hidden email]>
> > > wrote:
> > >
> > > > Hi Anil,
> > > >
> > > > You Can simply follow below steps:
> > > >
> > > > 1) Add a new thread group per your need basis.
> > > > 2) Select all the elements of the thread group -> copy them.
> > > > 3) Now right click the new thread group and click paste, your all the
> > > > elements will come inside this new thread group.
> > > > 4) Now you can delete or Disable the old thread group and continue
> the
> > > > execution with new thread group.
> > > >
> > > > Regards,
> > > > Indu Gupta
> > > >
> > > > -----Original Message-----
> > > > From: Anil Kumar [mailto:[hidden email]]
> > > > Sent: Friday, February 22, 2019 11:04
> > > > To: [hidden email]
> > > > Subject: JMeter Query on Threads
> > > >
> > > > Hi
> > > >
> > > > Is there a way to add thread group with in a thread group ?
> > > >
> > > > I have a scenario where a thread needs to run multiple threads, say
> > > > kind of forking..
> > > >
> > > > regards
> > > > Anil
> > > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [hidden email]
> > > For additional commands, e-mail: [hidden email]
> > >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

Brian Wolfe
how is step 1a different than step 1b1 and 1b2?
you talking about logging in to an app which creates a session based on an
user id. then creating additional user sessions while logged already logged
in?
If thread group 2 is a subset of actions taken by the initial user. you
should probably use the loop controller to go through a file that contains
the subset user data and use that to do the work. Those actions won't
happen concurrently as if it were a thread group tho. Is it necessary that
the actions in the thread group happen concurrently?
Its kinda messy from a programming perspective to have threads creating
more threads of which they are dependent upon, which is likely why they
didn't allow that to begin with.

On Fri, Feb 22, 2019 at 10:36 AM Anil Kumar <[hidden email]> wrote:

> No, we cannot. If we increase,  each thread starts invoking Step 1a:
> (above)  and consuming all licenses and also exhausting other resources.
> Ex: Step 1a:  should invoke once and later Step 1b1/Step 1b2: shoud invoke
> concurrently..
>
>
>
>
>
> On Fri, Feb 22, 2019 at 8:48 PM sebb <[hidden email]> wrote:
>
> > Can't you just increase the number of threads in the thread group?
> >
> > On Fri, 22 Feb 2019 at 14:47, Anil Kumar <[hidden email]>
> wrote:
> > >
> > > Hi Indu,
> > >
> > > Thank you for taking you time...
> > >
> > > We have consider your scenario, but loop controller had a limitation of
> > > exec samples sequentially.
> > > We rather looking for a solution which pump load concurrently (i.e.,
> the
> > > reason we are looking for an option of forking / threads ).
> > >
> > > Warm Regards
> > > Anil
> > >
> > > On Fri, Feb 22, 2019 at 7:45 PM Indu Gupta <[hidden email]>
> > wrote:
> > >
> > > > Hi Anil,
> > > >
> > > > You can add "Loop Controller" within Thread Group  (Right click
> Thread
> > > > Group -> Logic Controller -> Loop Controller).
> > > > Set number of Loop Count as "2" for 2 user sessions.
> > > >
> > > > The test plan structure will look like:
> > > >
> > > > Thread Group
> > > >     -Login Request
> > > >    - Loop Controller
> > > >         - User sessions
> > > >
> > > > It will run 1 cycle of test like : 1 login request then 2 user
> session.
> > > >
> > > > Hope your query is resolved now.
> > > >
> > > >
> > > > Regards,
> > > > Indu Gupta
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: Anil Kumar [mailto:[hidden email]]
> > > > Sent: Friday, February 22, 2019 12:18
> > > > To: JMeter Users List <[hidden email]>
> > > > Cc: Naveen Nandwani <[hidden email]>; Sanjeev Anand <
> > > > [hidden email]>
> > > > Subject: Re: JMeter Query on Threads
> > > >
> > > > thank you for quick response,
> > > >
> > > > i am trying here
> > > >
> > > > Step 1 :start Thread Group 1
> > > >                  Step 1a: Create a  Login Session
> > > >                  Step 1b: start Thread Group 2
> > > >                                 Step 1b1: Create a  User Session 1
> > > >                                 Step 1b2: Create a  User Session 2
> > > >                  Step 1c: exit Thread Group 2 Step 2: exit Thread
> > Group 1
> > > >
> > > > Is this possible? assume which you mentioned above is different.
> > > >
> > > >
> > > >
> > > > On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <
> [hidden email]>
> > > > wrote:
> > > >
> > > > > Hi Anil,
> > > > >
> > > > > You Can simply follow below steps:
> > > > >
> > > > > 1) Add a new thread group per your need basis.
> > > > > 2) Select all the elements of the thread group -> copy them.
> > > > > 3) Now right click the new thread group and click paste, your all
> the
> > > > > elements will come inside this new thread group.
> > > > > 4) Now you can delete or Disable the old thread group and continue
> > the
> > > > > execution with new thread group.
> > > > >
> > > > > Regards,
> > > > > Indu Gupta
> > > > >
> > > > > -----Original Message-----
> > > > > From: Anil Kumar [mailto:[hidden email]]
> > > > > Sent: Friday, February 22, 2019 11:04
> > > > > To: [hidden email]
> > > > > Subject: JMeter Query on Threads
> > > > >
> > > > > Hi
> > > > >
> > > > > Is there a way to add thread group with in a thread group ?
> > > > >
> > > > > I have a scenario where a thread needs to run multiple threads, say
> > > > > kind of forking..
> > > > >
> > > > > regards
> > > > > Anil
> > > > >
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: [hidden email]
> > > > For additional commands, e-mail: [hidden email]
> > > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >
> >
>


--
Thanks,
Brian Wolfe
https://www.linkedin.com/in/brian-wolfe-3136425a/
Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

Anil Kumar
how is step 1a different than step 1b1 and 1b2?
you talking about logging in to an app which creates a session based on an
user id. then creating additional user sessions while logged already logged
in?
Anil > Yes

If thread group 2 is a subset of actions taken by the initial user. you
should probably use the loop controller to go through a file that contains
the subset user data and use that to do the work. Those actions won't
happen concurrently as if it were a thread group tho. Is it necessary that
the actions in the thread group happen concurrently?
Anil > Yes

Its kinda messy from a programming perspective to have threads creating
more threads of which they are dependent upon, which is likely why they
didn't allow that to begin with.

On Fri, Feb 22, 2019 at 9:48 PM Brian Wolfe <[hidden email]>
wrote:

> how is step 1a different than step 1b1 and 1b2?
> you talking about logging in to an app which creates a session based on an
> user id. then creating additional user sessions while logged already logged
> in?
> If thread group 2 is a subset of actions taken by the initial user. you
> should probably use the loop controller to go through a file that contains
> the subset user data and use that to do the work. Those actions won't
> happen concurrently as if it were a thread group tho. Is it necessary that
> the actions in the thread group happen concurrently?
> Its kinda messy from a programming perspective to have threads creating
> more threads of which they are dependent upon, which is likely why they
> didn't allow that to begin with.
>
> On Fri, Feb 22, 2019 at 10:36 AM Anil Kumar <[hidden email]>
> wrote:
>
> > No, we cannot. If we increase,  each thread starts invoking Step 1a:
> > (above)  and consuming all licenses and also exhausting other resources.
> > Ex: Step 1a:  should invoke once and later Step 1b1/Step 1b2: shoud
> invoke
> > concurrently..
> >
> >
> >
> >
> >
> > On Fri, Feb 22, 2019 at 8:48 PM sebb <[hidden email]> wrote:
> >
> > > Can't you just increase the number of threads in the thread group?
> > >
> > > On Fri, 22 Feb 2019 at 14:47, Anil Kumar <[hidden email]>
> > wrote:
> > > >
> > > > Hi Indu,
> > > >
> > > > Thank you for taking you time...
> > > >
> > > > We have consider your scenario, but loop controller had a limitation
> of
> > > > exec samples sequentially.
> > > > We rather looking for a solution which pump load concurrently (i.e.,
> > the
> > > > reason we are looking for an option of forking / threads ).
> > > >
> > > > Warm Regards
> > > > Anil
> > > >
> > > > On Fri, Feb 22, 2019 at 7:45 PM Indu Gupta <[hidden email]
> >
> > > wrote:
> > > >
> > > > > Hi Anil,
> > > > >
> > > > > You can add "Loop Controller" within Thread Group  (Right click
> > Thread
> > > > > Group -> Logic Controller -> Loop Controller).
> > > > > Set number of Loop Count as "2" for 2 user sessions.
> > > > >
> > > > > The test plan structure will look like:
> > > > >
> > > > > Thread Group
> > > > >     -Login Request
> > > > >    - Loop Controller
> > > > >         - User sessions
> > > > >
> > > > > It will run 1 cycle of test like : 1 login request then 2 user
> > session.
> > > > >
> > > > > Hope your query is resolved now.
> > > > >
> > > > >
> > > > > Regards,
> > > > > Indu Gupta
> > > > >
> > > > >
> > > > > -----Original Message-----
> > > > > From: Anil Kumar [mailto:[hidden email]]
> > > > > Sent: Friday, February 22, 2019 12:18
> > > > > To: JMeter Users List <[hidden email]>
> > > > > Cc: Naveen Nandwani <[hidden email]>; Sanjeev
> Anand <
> > > > > [hidden email]>
> > > > > Subject: Re: JMeter Query on Threads
> > > > >
> > > > > thank you for quick response,
> > > > >
> > > > > i am trying here
> > > > >
> > > > > Step 1 :start Thread Group 1
> > > > >                  Step 1a: Create a  Login Session
> > > > >                  Step 1b: start Thread Group 2
> > > > >                                 Step 1b1: Create a  User Session 1
> > > > >                                 Step 1b2: Create a  User Session 2
> > > > >                  Step 1c: exit Thread Group 2 Step 2: exit Thread
> > > Group 1
> > > > >
> > > > > Is this possible? assume which you mentioned above is different.
> > > > >
> > > > >
> > > > >
> > > > > On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <
> > [hidden email]>
> > > > > wrote:
> > > > >
> > > > > > Hi Anil,
> > > > > >
> > > > > > You Can simply follow below steps:
> > > > > >
> > > > > > 1) Add a new thread group per your need basis.
> > > > > > 2) Select all the elements of the thread group -> copy them.
> > > > > > 3) Now right click the new thread group and click paste, your all
> > the
> > > > > > elements will come inside this new thread group.
> > > > > > 4) Now you can delete or Disable the old thread group and
> continue
> > > the
> > > > > > execution with new thread group.
> > > > > >
> > > > > > Regards,
> > > > > > Indu Gupta
> > > > > >
> > > > > > -----Original Message-----
> > > > > > From: Anil Kumar [mailto:[hidden email]]
> > > > > > Sent: Friday, February 22, 2019 11:04
> > > > > > To: [hidden email]
> > > > > > Subject: JMeter Query on Threads
> > > > > >
> > > > > > Hi
> > > > > >
> > > > > > Is there a way to add thread group with in a thread group ?
> > > > > >
> > > > > > I have a scenario where a thread needs to run multiple threads,
> say
> > > > > > kind of forking..
> > > > > >
> > > > > > regards
> > > > > > Anil
> > > > > >
> > > > >
> > > > >
> ---------------------------------------------------------------------
> > > > > To unsubscribe, e-mail: [hidden email]
> > > > > For additional commands, e-mail: [hidden email]
> > > > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [hidden email]
> > > For additional commands, e-mail: [hidden email]
> > >
> > >
> >
>
>
> --
> Thanks,
> Brian Wolfe
> https://www.linkedin.com/in/brian-wolfe-3136425a/
>
Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

shettyd
Hi
there is no way to nest thread groups(that I know off) but you can use
sequential thread groups and exchange data between them (using usual
mechanisms of anything shared like a file or db or service or queue)
Thread Group 1 (n threads)
+ Do something
+ Save it somewhere
Thread Group 2 (m threads)
+Read it from somewhere
+Do something else

You can do the same thing in a single thread group by writing more code
Thread group (max number of threads needed)
+If thread number satisifies custom condition
++ Do something
++ Save it in some form
+Synchronizing controller (all threads)
++ read and do something


regards
deepak


On Fri, Feb 22, 2019 at 6:16 PM Anil Kumar <[hidden email]> wrote:

> how is step 1a different than step 1b1 and 1b2?
> you talking about logging in to an app which creates a session based on an
> user id. then creating additional user sessions while logged already logged
> in?
> Anil > Yes
>
> If thread group 2 is a subset of actions taken by the initial user. you
> should probably use the loop controller to go through a file that contains
> the subset user data and use that to do the work. Those actions won't
> happen concurrently as if it were a thread group tho. Is it necessary that
> the actions in the thread group happen concurrently?
> Anil > Yes
>
> Its kinda messy from a programming perspective to have threads creating
> more threads of which they are dependent upon, which is likely why they
> didn't allow that to begin with.
>
> On Fri, Feb 22, 2019 at 9:48 PM Brian Wolfe <[hidden email]>
> wrote:
>
> > how is step 1a different than step 1b1 and 1b2?
> > you talking about logging in to an app which creates a session based on
> an
> > user id. then creating additional user sessions while logged already
> logged
> > in?
> > If thread group 2 is a subset of actions taken by the initial user. you
> > should probably use the loop controller to go through a file that
> contains
> > the subset user data and use that to do the work. Those actions won't
> > happen concurrently as if it were a thread group tho. Is it necessary
> that
> > the actions in the thread group happen concurrently?
> > Its kinda messy from a programming perspective to have threads creating
> > more threads of which they are dependent upon, which is likely why they
> > didn't allow that to begin with.
> >
> > On Fri, Feb 22, 2019 at 10:36 AM Anil Kumar <[hidden email]>
> > wrote:
> >
> > > No, we cannot. If we increase,  each thread starts invoking Step 1a:
> > > (above)  and consuming all licenses and also exhausting other
> resources.
> > > Ex: Step 1a:  should invoke once and later Step 1b1/Step 1b2: shoud
> > invoke
> > > concurrently..
> > >
> > >
> > >
> > >
> > >
> > > On Fri, Feb 22, 2019 at 8:48 PM sebb <[hidden email]> wrote:
> > >
> > > > Can't you just increase the number of threads in the thread group?
> > > >
> > > > On Fri, 22 Feb 2019 at 14:47, Anil Kumar <[hidden email]>
> > > wrote:
> > > > >
> > > > > Hi Indu,
> > > > >
> > > > > Thank you for taking you time...
> > > > >
> > > > > We have consider your scenario, but loop controller had a
> limitation
> > of
> > > > > exec samples sequentially.
> > > > > We rather looking for a solution which pump load concurrently
> (i.e.,
> > > the
> > > > > reason we are looking for an option of forking / threads ).
> > > > >
> > > > > Warm Regards
> > > > > Anil
> > > > >
> > > > > On Fri, Feb 22, 2019 at 7:45 PM Indu Gupta <
> [hidden email]
> > >
> > > > wrote:
> > > > >
> > > > > > Hi Anil,
> > > > > >
> > > > > > You can add "Loop Controller" within Thread Group  (Right click
> > > Thread
> > > > > > Group -> Logic Controller -> Loop Controller).
> > > > > > Set number of Loop Count as "2" for 2 user sessions.
> > > > > >
> > > > > > The test plan structure will look like:
> > > > > >
> > > > > > Thread Group
> > > > > >     -Login Request
> > > > > >    - Loop Controller
> > > > > >         - User sessions
> > > > > >
> > > > > > It will run 1 cycle of test like : 1 login request then 2 user
> > > session.
> > > > > >
> > > > > > Hope your query is resolved now.
> > > > > >
> > > > > >
> > > > > > Regards,
> > > > > > Indu Gupta
> > > > > >
> > > > > >
> > > > > > -----Original Message-----
> > > > > > From: Anil Kumar [mailto:[hidden email]]
> > > > > > Sent: Friday, February 22, 2019 12:18
> > > > > > To: JMeter Users List <[hidden email]>
> > > > > > Cc: Naveen Nandwani <[hidden email]>; Sanjeev
> > Anand <
> > > > > > [hidden email]>
> > > > > > Subject: Re: JMeter Query on Threads
> > > > > >
> > > > > > thank you for quick response,
> > > > > >
> > > > > > i am trying here
> > > > > >
> > > > > > Step 1 :start Thread Group 1
> > > > > >                  Step 1a: Create a  Login Session
> > > > > >                  Step 1b: start Thread Group 2
> > > > > >                                 Step 1b1: Create a  User Session
> 1
> > > > > >                                 Step 1b2: Create a  User Session
> 2
> > > > > >                  Step 1c: exit Thread Group 2 Step 2: exit Thread
> > > > Group 1
> > > > > >
> > > > > > Is this possible? assume which you mentioned above is different.
> > > > > >
> > > > > >
> > > > > >
> > > > > > On Fri, Feb 22, 2019 at 11:25 AM Indu Gupta <
> > > [hidden email]>
> > > > > > wrote:
> > > > > >
> > > > > > > Hi Anil,
> > > > > > >
> > > > > > > You Can simply follow below steps:
> > > > > > >
> > > > > > > 1) Add a new thread group per your need basis.
> > > > > > > 2) Select all the elements of the thread group -> copy them.
> > > > > > > 3) Now right click the new thread group and click paste, your
> all
> > > the
> > > > > > > elements will come inside this new thread group.
> > > > > > > 4) Now you can delete or Disable the old thread group and
> > continue
> > > > the
> > > > > > > execution with new thread group.
> > > > > > >
> > > > > > > Regards,
> > > > > > > Indu Gupta
> > > > > > >
> > > > > > > -----Original Message-----
> > > > > > > From: Anil Kumar [mailto:[hidden email]]
> > > > > > > Sent: Friday, February 22, 2019 11:04
> > > > > > > To: [hidden email]
> > > > > > > Subject: JMeter Query on Threads
> > > > > > >
> > > > > > > Hi
> > > > > > >
> > > > > > > Is there a way to add thread group with in a thread group ?
> > > > > > >
> > > > > > > I have a scenario where a thread needs to run multiple threads,
> > say
> > > > > > > kind of forking..
> > > > > > >
> > > > > > > regards
> > > > > > > Anil
> > > > > > >
> > > > > >
> > > > > >
> > ---------------------------------------------------------------------
> > > > > > To unsubscribe, e-mail: [hidden email]
> > > > > > For additional commands, e-mail: [hidden email]
> > > > > >
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: [hidden email]
> > > > For additional commands, e-mail: [hidden email]
> > > >
> > > >
> > >
> >
> >
> > --
> > Thanks,
> > Brian Wolfe
> > https://www.linkedin.com/in/brian-wolfe-3136425a/
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: JMeter Query on Threads

glinius@live.com
In reply to this post by Anil Kumar
Using vanilla JMeter it is very tricky, nearly impossible.

Consider using  Parallel Controller
<https://www.blazemeter.com/blog/how-to-use-the-parallel-controller-in-jmeter>
, it's main goal is simulating  AJAX
<https://en.wikipedia.org/wiki/Ajax_(programming)>   requests  which have
the same "forking" nature as you're looking for.

You can install Parallel Controller using  JMeter Plugins Manager
<https://www.blazemeter.com/blog/how-install-jmeter-plugins-manager>  



--
Sent from: http://www.jmeter-archive.org/JMeter-User-f512775.html

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

JMeter Query on Threads

Philippe Mouawad
Hello,

Maybe you should reconsider what you are trying to do.
It looks from my understanding like a workaround to try to simulate more
threads than licenses you have. If it's the case, approach is wrong.

If aim is different, you may want to look at:
- https://jmeter-plugins.org/wiki/InterThreadCommunication/

Regards
Philippe M.
https://leanpub.com/master-jmeter-from-load-test-to-devops

On Mon, Feb 25, 2019 at 5:52 PM [hidden email] <[hidden email]> wrote:

> Using vanilla JMeter it is very tricky, nearly impossible.
>
> Consider using  Parallel Controller
> <https://www.blazemeter.com/blog/how-to-use-the-parallel-
> controller-in-jmeter>
> , it's main goal is simulating  AJAX
> <https://en.wikipedia.org/wiki/Ajax_(programming)>   requests  which have
> the same "forking" nature as you're looking for.
>
> You can install Parallel Controller using  JMeter Plugins Manager
> <https://www.blazemeter.com/blog/how-install-jmeter-plugins-manager>
>
>
>
> --
> Sent from: http://www.jmeter-archive.org/JMeter-User-f512775.html
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>





<https://www.openstreetmap.org/#map=18/50.69454/3.16455>


--


[image: logo Ubik Ingenierie] <https://www.ubik-ingenierie.com> Philippe
Mouawad
Senior Performance Expert
320914981 <+33320914981> | [hidden email]
[image: ubik-ingenierie.com] ubik-ingenierie.com
<https://www.ubik-ingenierie.com> | [image: 03.20.91.49.81] 03.20.91.49.81
<+33320914981> | [image: 23 rue du chemin de fer , 59100 , Roubaix] 23 rue
du chemin de fer, 59100, Roubaix
<https://www.openstreetmap.org/#map=18/50.69454/3.16455>
Philippe M.
@philmdot
http://ubikloadpack.com