Re: 700 ~ users to run in Jmeter test performing post methods using rest api

2016-11-18 Thread Pravesh Prajapati
Hi Anusuya,

Please let us know what is the complexity of your load test scripts & which
Protocol your Application is using.
Your Hardware configuration, will depends on the factors.
If your application is using http protocol & Scripts are simple, you can
execute your App 600 users on with your mentioned configuration.

Please run you scripts into non gui mode without any listener.

Regards,
Pravesh P.

On Fri, Nov 18, 2016 at 10:31 PM, anusuya bhan  wrote:

> Hello all,
>
> Quick query I am facing issues while doing distributed testing using Jmeter
> 3.0, I doubt some firewall issue
>
> I have to run a  test for 725  users on windows desktop config of which are
> 4 GB RAM and 64 bit windows 7.
>
> Most of my requests are rest api , running multiple thread groups of 5 with
> rest api requests in each.
>
> Should I go ahead with running this test in a single machine for one hour?
>
> Quick replies will be helpful.
>
> Thanks and regards
> Anusuya
>



-- 
Regards,
Pravesh prajapati.
Mob:-9702600170


500 Server Error occurs only in JMeter, same POST is successful when submitted manually

2016-11-18 Thread Hohmann, Kurt D
In my script, I'm using a JSESSIONID instead of a cookie; the JSESSIONID is 
extracted using a HTTP URL Re-writing Modifier and I can confirm that the 
correct value (the one which appears in the response data from the login page) 
is being applied in the Request.
e.g. POST 
https://qa67.ososinfo.org:446/Staff/staffdetail.xhtml;JSESSIONID=0655ca5420354753ae413984d34cfc27

I'm also using a VIEWSTATE, which I'm extracting prior to running the remainder 
of the test steps by using a Regular Expression Extractor and setting the 
resulting variable as a parameter in the HTTP Request,
e.g. javax.faces.ViewState=8d2%2BgOIseczB2FWSo74DqQfkmiYVaK73D8bnLTNWCx%2FB8EtE

The problem is that I'm hitting a Response code: 500 | Response message: 
Internal Server Error every time I attempt a post with all of the applicable 
data.

I tried running through the steps manually in a Firefox browser. I copied the 
contents of the Request tab from the failing page into a REST client, logged in 
using a separate tab of the same browser and grabbed the appropriate JSESSIONID 
and VIEWSTATE information, then posted with that info in place - and the manual 
post was successful.

Am I missing something? Is JMeter requiring something to accomplish this POST 
that a I'm not seeing in a manual attempt?

Happy to share any/all of what I'm seeing if it might be helpful in helping to 
troubleshoot.

Thanks,
Kurt


700 ~ users to run in Jmeter test performing post methods using rest api

2016-11-18 Thread anusuya bhan
Hello all,

Quick query I am facing issues while doing distributed testing using Jmeter
3.0, I doubt some firewall issue

I have to run a  test for 725  users on windows desktop config of which are
4 GB RAM and 64 bit windows 7.

Most of my requests are rest api , running multiple thread groups of 5 with
rest api requests in each.

Should I go ahead with running this test in a single machine for one hour?

Quick replies will be helpful.

Thanks and regards
Anusuya


Re: BeanShell Assertion in jdbc request

2016-11-18 Thread sebb
On 18 November 2016 at 15:10, Sankar Das <007bhabanisan...@gmail.com> wrote:
> Hi,
>
> Thanks for the reply. Yes I am able to capture it.
>
> But my query is "SELECT STATUS,COUNT(*) FROM MYTABLE WHERE CREATIONTIME >
> TRUNC(SYSDATE) GROUP BY STATUS"
>
> So I have two columns here ID_# and WF_# and the rows will increase and
> decrease according to the sysdate.

ID_# and WF_# are not columns.

They are row counts, i.e. the number of ID_1,...ID_n and WF_1,...WF_n variables

>
> I want to do like this,
>
> If column1_row1_ ID_1 = Waiting and column2_row1_WF_1 > 25, than fail the
> sampler  "Failure = true".
>
> But the rows values are changing according to sysdate.
>
> so want to capture all the rows value

You already have the values in the variables ID_1...ID_n and WF_1...WF_n
And the counts are in ID_# and WF_#

> and compare them on run time and make
> the sampler "failure true or false".
>

You wrote "Above code is working when I know the number of rows for a particular
column. "

I provided details on how to extract the row count.

And you can get the value of a variable using vars.get(varname) where
varname is a string containing the variable name.

BeanShell is basically Java, so you can loop through values of n from
1 to ID_# and pick out the values:

for (int i=1; i
>
>
> On Fri, Nov 18, 2016 at 4:48 PM, sebb  wrote:
>
>> On 18 November 2016 at 14:15, Sankar Das <007bhabanisan...@gmail.com>
>> wrote:
>> > Hello Everyone,
>> >
>> > Getting two columns from a jdbc sampler  i.e ID and WF. Trying to fail
>> it,
>> > if it exceeds than the predefined variables by using beanshell.
>> > Below is the sample code.
>> >
>> > String myValue1 = vars.get("WF_1");
>> > String myValue2 = vars.get("WF_2");
>> > if(!myValue1.equals ("3")){
>> >   log.info("myValue1 =" + myValue1);
>> >   Failure = true;
>> >   FailureMessage = " The database value should be " + myValue1 + ".";
>> > }
>> > else if(!myValue2.equals ("5")){
>> >   //log something
>> >   Failure = true;
>> >   log.info("myValue2 =" + myValue2);
>> >FailureMessage = " The database value should be " + myValue2 + ".";
>> >
>> > else {
>> >   //can be log something?
>> >  Failure = false;
>> >
>> >
>> > }
>> > Above code is working when I know the number of rows for a particular
>> > column. If the rows values are dynamic and increasing or decreasing
>> > according to sysdate than how to compare them with the predefined and
>> fail
>> > the sampler.
>> >
>> > Please help!
>>
>> As per http://jmeter.apache.org/usermanual/component_
>> reference.html#JDBC_Request
>>
>> the number of rows is stored in the variables
>>
>> ID_# and WF_#
>>
>> > Thanks!
>>
>> -
>> To unsubscribe, e-mail: user-unsubscr...@jmeter.apache.org
>> For additional commands, e-mail: user-h...@jmeter.apache.org
>>
>>

-
To unsubscribe, e-mail: user-unsubscr...@jmeter.apache.org
For additional commands, e-mail: user-h...@jmeter.apache.org



Re: BeanShell Assertion in jdbc request

2016-11-18 Thread Sankar Das
Hi,

Thanks for the reply. Yes I am able to capture it.

But my query is "SELECT STATUS,COUNT(*) FROM MYTABLE WHERE CREATIONTIME >
TRUNC(SYSDATE) GROUP BY STATUS"

So I have two columns here ID_# and WF_# and the rows will increase and
decrease according to the sysdate.
I want to do like this,

If column1_row1_ ID_1 = Waiting and column2_row1_WF_1 > 25, than fail the
sampler  "Failure = true".

But the rows values are changing according to sysdate.

so want to capture all the rows value and compare them on run time and make
the sampler "failure true or false".





On Fri, Nov 18, 2016 at 4:48 PM, sebb  wrote:

> On 18 November 2016 at 14:15, Sankar Das <007bhabanisan...@gmail.com>
> wrote:
> > Hello Everyone,
> >
> > Getting two columns from a jdbc sampler  i.e ID and WF. Trying to fail
> it,
> > if it exceeds than the predefined variables by using beanshell.
> > Below is the sample code.
> >
> > String myValue1 = vars.get("WF_1");
> > String myValue2 = vars.get("WF_2");
> > if(!myValue1.equals ("3")){
> >   log.info("myValue1 =" + myValue1);
> >   Failure = true;
> >   FailureMessage = " The database value should be " + myValue1 + ".";
> > }
> > else if(!myValue2.equals ("5")){
> >   //log something
> >   Failure = true;
> >   log.info("myValue2 =" + myValue2);
> >FailureMessage = " The database value should be " + myValue2 + ".";
> >
> > else {
> >   //can be log something?
> >  Failure = false;
> >
> >
> > }
> > Above code is working when I know the number of rows for a particular
> > column. If the rows values are dynamic and increasing or decreasing
> > according to sysdate than how to compare them with the predefined and
> fail
> > the sampler.
> >
> > Please help!
>
> As per http://jmeter.apache.org/usermanual/component_
> reference.html#JDBC_Request
>
> the number of rows is stored in the variables
>
> ID_# and WF_#
>
> > Thanks!
>
> -
> To unsubscribe, e-mail: user-unsubscr...@jmeter.apache.org
> For additional commands, e-mail: user-h...@jmeter.apache.org
>
>


Re: BeanShell Assertion in jdbc request

2016-11-18 Thread sebb
On 18 November 2016 at 14:15, Sankar Das <007bhabanisan...@gmail.com> wrote:
> Hello Everyone,
>
> Getting two columns from a jdbc sampler  i.e ID and WF. Trying to fail it,
> if it exceeds than the predefined variables by using beanshell.
> Below is the sample code.
>
> String myValue1 = vars.get("WF_1");
> String myValue2 = vars.get("WF_2");
> if(!myValue1.equals ("3")){
>   log.info("myValue1 =" + myValue1);
>   Failure = true;
>   FailureMessage = " The database value should be " + myValue1 + ".";
> }
> else if(!myValue2.equals ("5")){
>   //log something
>   Failure = true;
>   log.info("myValue2 =" + myValue2);
>FailureMessage = " The database value should be " + myValue2 + ".";
>
> else {
>   //can be log something?
>  Failure = false;
>
>
> }
> Above code is working when I know the number of rows for a particular
> column. If the rows values are dynamic and increasing or decreasing
> according to sysdate than how to compare them with the predefined and fail
> the sampler.
>
> Please help!

As per http://jmeter.apache.org/usermanual/component_reference.html#JDBC_Request

the number of rows is stored in the variables

ID_# and WF_#

> Thanks!

-
To unsubscribe, e-mail: user-unsubscr...@jmeter.apache.org
For additional commands, e-mail: user-h...@jmeter.apache.org



BeanShell Assertion in jdbc request

2016-11-18 Thread Sankar Das
Hello Everyone,

Getting two columns from a jdbc sampler  i.e ID and WF. Trying to fail it,
if it exceeds than the predefined variables by using beanshell.
Below is the sample code.

String myValue1 = vars.get("WF_1");
String myValue2 = vars.get("WF_2");
if(!myValue1.equals ("3")){
  log.info("myValue1 =" + myValue1);
  Failure = true;
  FailureMessage = " The database value should be " + myValue1 + ".";
}
else if(!myValue2.equals ("5")){
  //log something
  Failure = true;
  log.info("myValue2 =" + myValue2);
   FailureMessage = " The database value should be " + myValue2 + ".";

else {
  //can be log something?
 Failure = false;


}
Above code is working when I know the number of rows for a particular
column. If the rows values are dynamic and increasing or decreasing
according to sysdate than how to compare them with the predefined and fail
the sampler.

Please help!

Thanks!