On 22/11/2007, Joseph Ribin Roy <[EMAIL PROTECTED]> wrote:
>
> hi sebb
>
> I have written a bean shell script which would return me 0,1,2 from the
> random generation. but the switch is not working fine. Its not sending
> request in expected order. I had read the issue in users mailing list. is it
> a bug
Are you sure that the script is returning the correct values?
Add a Java Request sampler to check it, or enclose the function call in __log().
e.g. ${__log(${__beanShell(function code)})}
The Switch Controller should look like:
Switch Controller
+ Sampler 0
+ Sampler 1
+ Sampler 2
or you could use Simple Controller parents:
Switch Controller
+ Simple Controller
+ + Sampler 0
+ Simple Controller
+ + Sampler 1
+ Simple Controller
+ + Sampler 2
> so i thought of trying through put controller. i am not still clear how can i
> proportionate using Throughput controller. can you through some light on this.
Just use a TC with the appropriate percentage as the parent of each sampler:
TC 1 (50%)
+ sampler 1
TC 2 (30%)
+ sampler 2
etc.
> ________________________________
>
> From: sebb [mailto:[EMAIL PROTECTED]
> Sent: Wed 11/21/2007 9:09 PM
> To: JMeter Users List
> Subject: Re: Proportioning of Request
>
>
>
> You could try:
>
> http://jakarta.apache.org/jmeter/usermanual/component_reference.html#Throughput_Controller
>
> You would need one as a parent of each request, and you may not get
> exactly one of the samples per loop.
>
> Otherwise, I would probably use the Switch Controller:
>
> http://jakarta.apache.org/jmeter/usermanual/component_reference.html#Switch_Controller
>
> in conjunction with a function that returns 0,1 or 2 in the
> appropriate proportions.
>
> e.g. generate a random number between 1 and 10 (inclusive) and then
> divide into suitable portions:
>
> 1-5 -> 0
> 6-8 -> 1
> 9-10 -> 2
>
> You could use javascript, jexl or beanshell for this.
>
> On 21/11/2007, Joseph Ribin Roy <[EMAIL PROTECTED]> wrote:
> >
> > Hi all,
> >
> > I have 3 http request. Is it possible to send it in 50:30:20 ratio.
> > Does any controller can do it. Putting it in different Thread group will
> > help in doing it [spliting the user proportion]. But I ll have to rewrite
> > other requests in all thread groups. Can any one through some light on this.
> >
> > Thanks
> > Joseph
> >
> >
> >
> > The information contained in, or attached to, this e-mail, contains
> > confidential information and is intended solely for the use of the
> > individual or entity to whom they are addressed and is subject to legal
> > privilege. If you have received this e-mail in error you should notify the
> > sender immediately by reply e-mail, delete the message from your system and
> > notify your system manager. Please do not copy it for any purpose, or
> > disclose its contents to any other person. The views or opinions presented
> > in this e-mail are solely those of the author and do not necessarily
> > represent those of the company. The recipient should check this e-mail and
> > any attachments for the presence of viruses. The company accepts no
> > liability for any damage caused, directly or indirectly, by any virus
> > transmitted in this email.
> >
> > www.aztecsoft.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
>
>
>
> The information contained in, or attached to, this e-mail, contains
> confidential information and is intended solely for the use of the individual
> or entity to whom they are addressed and is subject to legal privilege. If
> you have received this e-mail in error you should notify the sender
> immediately by reply e-mail, delete the message from your system and notify
> your system manager. Please do not copy it for any purpose, or disclose its
> contents to any other person. The views or opinions presented in this e-mail
> are solely those of the author and do not necessarily represent those of the
> company. The recipient should check this e-mail and any attachments for the
> presence of viruses. The company accepts no liability for any damage caused,
> directly or indirectly, by any virus transmitted in this email.
>
> www.aztecsoft.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]