[prev in list] [next in list] [prev in thread] [next in thread] 

List:       grinder-use
Subject:    Re: [Grinder-use] Batch execution and skipping tests in a run
From:       "Trilok Khairnar" <trilokgk () gmail ! com>
Date:       2007-06-18 15:57:08
Message-ID: 000501c7b1bf$a8c8f2c0$0d2d580a () persistent ! co ! in
[Download RAW message or body]

Yes, I am using Jython 2.2b2
The defect cannot be reproduced on another machine that also uses Jython
2.2b2, same JDK/JRE i.e. 1.6, and the same build of Grinder - also on
Windows XP. I will investigate it further to see what changes between the
two environments.

Thanks,
Trilok.

-----Original Message-----
From: grinder-use-bounces@lists.sourceforge.net
[mailto:grinder-use-bounces@lists.sourceforge.net] On Behalf Of Philip Aston
Sent: Wednesday, June 13, 2007 10:46 PM
To: grinder-use
Subject: Re: [Grinder-use] Batch execution and skipping tests in a run

Interesting.

The worker process is failing to exit properly due to a shutdown hook:

"main" prio=6 tid=0x00296400 nid=0xbb8 in Object.wait()
[0x0090f000..0x0090fe54]
java.lang.Thread.State: WAITING (on object monitor) at
java.lang.Object.wait(Native Method)
- waiting on <0x0f960728> (a org.python.core.PyFile$PyFileCloser)
at java.lang.Thread.join(Unknown Source)
- locked <0x0f960728> (a org.python.core.PyFile$PyFileCloser)
at java.lang.Thread.join(Unknown Source) at
java.lang.ApplicationShutdownHooks.run(Unknown Source) at
java.lang.Shutdown.runHooks(Unknown Source) at
java.lang.Shutdown.sequence(Unknown Source) at
java.lang.Shutdown.exit(Unknown Source)
- locked <0x2b734e70> (a java.lang.Class for java.lang.Shutdown) at
java.lang.Runtime.exit(Unknown Source) at java.lang.System.exit(Unknown
Source) at
net.grinder.engine.process.WorkerProcessEntryPoint.main(WorkerProcessEntryPo
int.java:61)

The lock the main thread is waiting for is held by:

"Jython Shutdown File Closer" prio=6 tid=0x0343b800 nid=0xe18 runnable
[0x0369f000..0x0369fa94]
java.lang.Thread.State: RUNNABLE
at java.io.FileInputStream.close0(Native Method) at
java.io.FileInputStream.close(Unknown Source) at
java.io.BufferedInputStream.close(Unknown Source) at
java.io.PushbackInputStream.close(Unknown Source)
- locked <0x0f961b70> (a java.io.PushbackInputStream) at
org.python.core.PyFile$InputStreamWrapper.close(Unknown Source) at
org.python.core.PyFile$TextWrapper.close(Unknown Source) at
org.python.core.PyFile$Closer._close(Unknown Source) at
org.python.core.PyFile$PyFileCloser.run(Unknown Source)
- locked <0x0f95fc58> (a java.util.LinkedList)


I'm not sure what version of Jython you are using. None of the versions
to which I have the source handy (2.1, 2.2alpha, 2.2b1) have a
PyFileCloser class. Perhaps worth trying a different version?

- Phil


Trilok Khairnar wrote:
> Thanks Phil.
>
> I should've mentioned that I built Grinder beta 33 source on my system
using
> JDK1.6, (the only customization was to use System.nanoTime in
> HTTPClient.HTTPConnection) and I'm running the agent using JRE 1.6
> I have attached the dumps taken using jstack.
>
> What I see on the screen is as follows:
>
> C:\grinderProjects\bin>java -cp
> C:\jython2.2b2\jython.jar;C:\grinder-3.0-beta33\
> lib\grinder.jar; net.grinder.Grinder
> C:\grinderProjects\etc\grinder.properties
> 6/13/07 11:16:56 AM (agent): The Grinder 3.0-beta33
> 6/13/07 11:16:57 AM (agent): Failed to connect to
> 'localhost/127.0.0.1:6372',
> proceeding without the console; set grinder.useConsole=false to disable
this
> warning.
> 6/13/07 11:16:57 AM (agent): Worker process command line: java
> '-Dcom.sun.management.jmxremote' '-mx400M' -classpath
> 'C:\jython2.2b2\jython.jar;C:\grinder-3.0-beta33\lib\grinder.jar;'
> net.grinder.engine.process.WorkerProcessEntryPoint
> 6/13/07 11:16:58 AM (agent): worker abc-0 started
> 6/13/07 11:16:59 AM (process abc-0): starting threads
> 6/13/07 11:17:28 AM (process abc-0): finished
>
> Thanks,
> Trilok
>
> -----Original Message-----
> From: grinder-use-bounces@lists.sourceforge.net
> [mailto:grinder-use-bounces@lists.sourceforge.net] On Behalf Of Philip
Aston
> Sent: Sunday, June 10, 2007 6:32 PM
> To: grinder-use
> Subject: Re: [Grinder-use] Batch execution and skipping tests in a run
>
> Trilok Khairnar wrote:
>
>
>> 1] We want to completely automate our test execution, and schedule a
>> series of tests to run unattended.
>> Consider the simple case where I run the tests without using a console
>> from a single agent.
>> The test agent prints a "finished" message when the test finishes,
>> however it does not exit. I would like the test agent to exit, so that
>> any postprocessing tasks (like collecting results, graphiing data
>> etc.)  can be run and the next scheduled test can be kicked off.
>> Is there any workaround to this? I think one solution is to listen to
>> the output of agent and kill the agent when the tests finish. If
>> multiple agents are involved, then all the agents need to signal that
they
>>
> have ended.
>
>> Am I missing any obvious means to do this on command line/ through
>> Grinder API?
>>
>>
>
> The agent process should exit by design. You should see something like
this:
>
> % java -cp ../lib/grinder.jar net.grinder.Grinder
> 10/06/07 13:56:10 (agent): The Grinder
> 3.0-beta32
> 10/06/07 13:56:10 (agent): Failed to connect to
> 'localhost/127.0.0.1:6372',
> proceeding without the console; set grinder.useConsole=false to disable
> this
> warning.
>
>
> 10/06/07 13:56:10 (agent): Worker process command line: java
> -classpath
> '../lib/grinder.jar'
> net.grinder.engine.process.WorkerProcessEntryPoint
> 10/06/07 13:56:10 (agent): worker paston01-0
> started
> 10/06/07 13:56:11 (process paston01-0): starting threads
> 10/06/07 13:56:11 (process paston01-0): finished
> 10/06/07 13:56:11 (agent):
> finished
> %
>
> I don't know why it doesn't exit. Can you take a thread dump of the agent
> when the test has finished?
>
>
> - Phil
>
>


Notice:  This email message, together with any attachments, may contain
information  of  BEA Systems,  Inc.,  its subsidiaries  and  affiliated
entities,  that may be confidential,  proprietary,  copyrighted  and/or
legally privileged, and is intended solely for the use of the individual or
entity named in this message. If you are not the intended recipient, and
have received this message in error, please immediately return this by email
and then delete it.

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
grinder-use mailing list
grinder-use@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/grinder-use



-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
grinder-use mailing list
grinder-use@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/grinder-use
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic