Alan Takaoka | 15 May 20:45
Favicon

grinder.duration, when is it checked?

Hi everyone!

When is grinder.duration enforced? Or how often is it checked?

For instance, is it monitored continuously such that a worker could 
abort mid script?

Or are scripts always run to completion and grinder.duration only 
checked between runs?

Thanks
-Alan

--

-- 

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
Timothy Madden | 15 May 14:36
Picon

Console defaults file

Hello

Are the properties in the console defaults file documented somewhere ? I 
could not find them with a search on the website documentation.

Is there a way to pass a different defaults file to the console (other than 
~/.grinder_console) ? 

I would like to run the console as part of an automated test process and I 
would like to preserve any settings the current user might already have in 
his/her ~/.console_grinder file, if any.

How does the headless mode work ? How do I send console commands in this 
mode ? Is there some documentation for that ?

Thank you,
Timothy Madden

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
Gary Mulder | 5 May 21:35
Favicon

Sample code for a composite test

Hi all,

 

I’m transcoding some nightmare Load Runner scripts into Grinder so that they can be executed automagically from a Jenkins job. This is all to avoid me becoming a “button punching monkey” ™ - running manual Load Runner tests every time some developer wants to try something new. Everything is going quite nicely, with a lot of C cruft being consumed by a caffeinated Python (sorry, it is late on a Saturday, and I couldn’t resist).

 

However, there is one feature in Load Runner that I don’t know how to reproduce in Grinder, namely composite transactions. It seems that there is reference in the Grinder lists and API to composite Tests, but no sample code. Does anyone have a sample of code on how to wrap N Test wrapped HTTPRequest objects into a composite Test?

 

Is it as simple as moving the N Test wrapped HTTPRequest objects into a method, and then wrapping that method?

 

Regards,

Gary


________________________________________________________________________
In order to protect our email recipients, Betfair Group use SkyScan from
MessageLabs to scan all Incoming and Outgoing mail for viruses.

________________________________________________________________________
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
grinder-use mailing list
grinder-use@...
https://lists.sourceforge.net/lists/listinfo/grinder-use
Ouray Viney | 2 May 18:00
Picon

Grinder 3.8 TCPProxy no longer adding basic authentication to requests...

Hi All:


Has anyone else noticed that Grinder 3.8 TCPProxy doesn't capture the basic authentication headers as it used to in 3.4?  Previously, TCPProxy would add the required basic authentication code to each request, now, nothing?  I was forced to manually enter it for each request, which is quite a bugger and time sapper.  

Question:  Is there a way to globally set the basic authentication that all requests should inherit?

I will log a bug when time permits, also once I have verified my recording steps aren't flawed.

-- 
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
grinder-use mailing list
grinder-use@...
https://lists.sourceforge.net/lists/listinfo/grinder-use
Ouray Viney | 30 Apr 23:03
Picon

Upgrade from Grinder 3.4 to Grinder 3.8 - no data file output and no sign of test script exec

Hi All:


I recently upgrade a system from 3.4 to 3.8.  Right out of the gates I see two problems, 1) data file is empty, 2) there is no error log.

I checked the file system and noticed that the out file was pretty small.

grinder <at> lingrnd13:/opt/home/testusr1/est/bdt1.1/log$ ls -lrt
total 4
-rw-r--r-- 1 testusr1 grnd   0 Apr 30 16:45 lingrnd13-0-data.log
-rw-r--r-- 1 testusr1 grnd 637 Apr 30 16:45 lingrnd13-0.log

So I checked the contents of the outfile:
 
grinder <at> lingrnd13:/opt/home/testusr1/est/bdt1.1/log$ cat lingrnd13-0.log
2012-04-30 16:45:20,758 INFO  lingrnd13-0 : The Grinder version 3.8
2012-04-30 16:45:20,763 INFO  lingrnd13-0 : Java(TM) SE Runtime Environment 1.6.0_13-b03: Java HotSpot(TM) Client VM (11.3-b02, mixed mode) on Linux i386 2.6.18-274.18.1.el5xen
2012-04-30 16:45:20,767 INFO  lingrnd13-0 : time zone is EDT (-0400)
2012-04-30 16:45:20,867 INFO  lingrnd13-0 : worker process 0 of agent number 0
2012-04-30 16:45:21,172 INFO  lingrnd13-0 : instrumentation agents: traditional Jython instrumenter; byte code transforming instrumenter for Java
2012-04-30 16:45:23,856 INFO  lingrnd13-0 : registered plug-in net.grinder.plugin.http.HTTPPlugin

Also, the console shows nothing, no updated stats.

Has something changed re: the agent/console start-up scripts?  Due to the fact that I am not getting any errors/exceptions, I don't have a lot to work with.  Please feel free to suggest ideas.

Kind Rgds,

--
Ouray Viney
http://www.viney.ca
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
grinder-use mailing list
grinder-use@...
https://lists.sourceforge.net/lists/listinfo/grinder-use
Picon
Gravatar

Writing Scripts In Java

Does anyone know of some sample load test scripts written in Java?

After spending some time looking in the Java API for Grinder, ( http://grinder.sourceforge.net/g3/script-javadoc/index.html ) I still don't understand how to create a test script and use the statistics and logger features.

Grinder.grinder and all related static fields seem to be uninitialized when using the API. I found that GrinderStone (older versions) worked by using Grinder and creating a ScriptContextImplementation as well as other classes in their weaver-src directory.

I would greatly appreciate any help.

Thanks,
Qays
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
grinder-use mailing list
grinder-use@...
https://lists.sourceforge.net/lists/listinfo/grinder-use
Perryn Fowler | 26 Apr 07:31
Picon

Scenarios?

Hi again,

Just starting to play with The Grinder and I have a (possibly stupid) question.

Often when load testing I want to set up several different usage 'Scenarios'

eg( for a 'for sale' app)
Scenario 1 - User:
                     searches for a for sale Item,
                     clicks through to a detail page for an item,
                     returns to search results,
                     clicks through to another detail page for another item

Scenario 2 - User:
                    logs in,
                    posts a new item for sale,
                    logs out

Scenario 3 - User
                     visits registration page,
                     registers,
                     logs in
                     posts a new item for sale,
                     logs out

etc etc

I would then have a whole bunch of threads repeatedly running Scenario
1, another bunch running Scenario 2 etc

At first glance I was expecting that I would write a script for each
scenario, and then allocate the scripts to different workers,
however it looks like grinder.properties only allows for a single
script to be specified per agent and all workers will run that script.

So it seems that to do what I want I need to
       a) run a separate agent for each scenario OR
       b) make the script able to run multiple scenarios in parallel (
using threads?)

What is the accepted way to do this sort of thing with The Grinder?

cheers
Perryn

--

-- 
-----------------------
Perryn Fowler
ThoughtWorks

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
Perryn Fowler | 26 Apr 06:20
Picon

Headless Mode and Console API?

Hi there,

I am currently evaluating The Grinder for performance/load testing of
our application. So far it looks pretty good.

The only hitch is that the standard way to control everything seems to
be via the Console Gui. We would want to run our tests as part of an
Automated Continuous Integration Pipeline.
This means we want to be able to control everything programatically
rather than via a GUI.

In the realease notes for 3.1 I found the following

"The console now has a "-headless" option which causes it to start
without the graphical user interface. This is useful when used with
the console client API"

but I cant seem to find any further documentation of either the
-headless option or the console client API.

Can anyone point me at the docs and/or give me some pointers/patterns
on using Grinder in a CI build?

cheers
Perryn

--

-- 
-----------------------
Perryn Fowler
ThoughtWorks

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
Tumri009 | 23 Apr 21:34
Picon
Favicon

Grinder Console CLOSE_WAIT sockets

Hello,

As part of my test environment setup, I run the console continuously and I restart the agents very frequently,  this agent restart creating CLOSE_WAIT sockets on CONSOLE, it looks console not handling socket close properly. Is there a fix this issue?  Do we need to fix it code?

Thanks,
Tumri

------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
grinder-use mailing list
grinder-use@...
https://lists.sourceforge.net/lists/listinfo/grinder-use
Mavlarn Tuohuti | 20 Apr 12:41
Picon

Error in script running.


I just test with a simple script, set process=1/thread=1/Duration=2minutes . 

#test
The script is very simple:
from net.grinder.script.Grinder import grinder
from net.grinder.script import Test
from net.grinder.plugin.http import HTTPRequest 

test1 = Test(1, "Request resource")
request1 = test1.wrap(HTTPRequest())

class TestRunner:
    def __call__(self):
        result = request1.GET("http://***.com")   ##line 11 is this, I marked the url as ***


And run till finished, but found there are 1 error in log.  I met this problem several times in these days. Can anyone tell me what it is the reason of that?  

Thanks.

========================================================================================================================
2012-04-19 19:02:54,213 INFO NC-PL-QA016-1 thread-0 [ run-63, test-1 ]: http://****/ -> 200 OK, 160497 bytes
2012-04-19 19:02:55,348 ERROR NC-PL-QA016-1 thread-0 [ run-63, test-1 ]: Aborted run: Java exception calling TestRunner
net.grinder.scriptengine.jython.JythonScriptExecutionException: Java exception calling TestRunner
File "/home/grinder_agent/bin/./NC-PL-QA016-file-store/current/Http_Grinder.py", line 11, in _call_
java.io.EOFException: Premature EOF encountered
at HTTPClient.StreamDemultiplexor.read(StreamDemultiplexor.java:300) ~[grinder-httpclient-3.7.1.jar:na]
at HTTPClient.RespInputStream.read(RespInputStream.java:155) ~[grinder-httpclient-3.7.1.jar:na]
at HTTPClient.HTTPResponse.readResponseData(HTTPResponse.java:1011) ~[grinder-httpclient-3.7.1.jar:na]
at HTTPClient.HTTPResponse.getData(HTTPResponse.java:515) ~[grinder-httpclient-3.7.1.jar:na]
at net.grinder.plugin.http.HTTPRequest$AbstractRequest.getHTTPResponse(HTTPRequest.java:1265) ~[grinder-http-3.7.1.jar:na]
at net.grinder.plugin.http.HTTPRequest.GET(HTTPRequest.java:503) ~[grinder-http-3.7.1.jar:na]
at net.grinder.plugin.http.HTTPRequest.GET(HTTPRequest.java:449) ~[grinder-http-3.7.1.jar:na]
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) ~[na:na]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.6.0_0]
at java.lang.reflect.Method.invoke(Method.java:616) ~[na:1.6.0_0]
at org.python.core.PyReflectedFunction._call_(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyMethod._call_(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyObject._call_(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyInstance.invoke(Unknown Source) ~[jython-2.2.1.jar:na]
at net.grinder.scriptengine.jython.instrumentation.traditional.InstrumentedPyJavaInstanceForJavaInstances.access$101(InstrumentedPyJavaInstanceForJav
aInstances.java:43) ~[grinder-core-3.7.1.jar:na]
at net.grinder.scriptengine.jython.instrumentation.traditional.InstrumentedPyJavaInstanceForJavaInstances$2.call(InstrumentedPyJavaInstanceForJavaIns
tances.java:70) ~[grinder-core-3.7.1.jar:na]
at net.grinder.scriptengine.jython.instrumentation.traditional.PyDispatcher.dispatch(PyDispatcher.java:70) ~[grinder-core-3.7.1.jar:na]
at net.grinder.scriptengine.jython.instrumentation.traditional.InstrumentationHelper.dispatch(InstrumentationHelper.java:101) ~[grinder-core-3.7.1.ja
r:na]
at net.grinder.scriptengine.jython.instrumentation.traditional.InstrumentedPyJavaInstanceForJavaInstances.invoke(InstrumentedPyJavaInstanceForJavaIns
tances.java:67) ~[grinder-core-3.7.1.jar:na]
at org.python.pycode.pyx1.call_$2(/home/ngrinder/ngrinder_agent-2.2/bin/./NC-PL-QA016-file-store/current/Http_Grinder.py:11) ~[na:na]
at org.python.pycode._pyx1.call_function(/home/ngrinder/ngrinder_agent-2.2/bin/./NC-PL-QA016-file-store/current/Http_Grinder.py) ~[na:na]
at org.python.core.PyTableCode.call(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyTableCode.call(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyTableCode.call(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyFunction._call_(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyMethod._call_(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyObject.invoke(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyInstance._call_(Unknown Source) ~[jython-2.2.1.jar:na]
at org.python.core.PyObject._call_(Unknown Source) ~[jython-2.2.1.jar:na]
at net.grinder.scriptengine.jython.JythonScriptEngine$JythonWorkerRunnable.run(JythonScriptEngine.java:250) ~[grinder-core-3.7.1.jar:na]
at net.grinder.engine.process.GrinderThread.run(GrinderThread.java:118) ~[grinder-core-3.7.1.jar:na]
at java.lang.Thread.run(Thread.java:636) [na:1.6.0_0]



------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
grinder-use mailing list
grinder-use@...
https://lists.sourceforge.net/lists/listinfo/grinder-use
Bill Smith | 19 Apr 21:39
Picon
Gravatar

what is the run number?

In Grinder, what is the run number?  To put it another way, what actions result in a new number (as opposed to a new thread number or a new process number)?  If you have an answer, feel free to earn yourself a few reputation points on StackExchange (http://sqa.stackexchange.com/questions/3035/in-the-grinder-what-is-a-run-number).


Bill Smith

------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
grinder-use mailing list
grinder-use@...
https://lists.sourceforge.net/lists/listinfo/grinder-use

Gmane