logo       

RE: Build loop hangs when jboss isn't stopped: msg#00061

java.cruise-control.user

Subject: RE: Build loop hangs when jboss isn't stopped

>> Why does it hang when launched from cruisecontrol?
 
What if you try running it with the same command-line that CC uses?
 
(Can use DEBUG to find that command line: http://c2.com/w4/cc/wiki.cgi?TurnOnDebug )
 
>> How can I avoid this?
 
Instead of doing haltonfailure with your junit task set a failure property, then after jboss is shutdown you can use the fail task to fail if that property is set. http://ant.apache.org/manual/OptionalTasks/junit.html
 
It would be something like:
 
<junit haltonfailure="off" failureproperty="test.failed" ...>
 
<stopjbosstask>
 
<fail if="test.failed" message="one or more tests failed" />
 
Jtf
 
-----Original Message-----
From: cruisecontrol-user-admin@xxxxxxxxxxxxxxxxxxxxx [mailto:cruisecontrol-user-admin@xxxxxxxxxxxxxxxxxxxxx] On Behalf Of François Eric
Sent: Wednesday, December 17, 2003 8:10 AM
To: Cruise-Control-User (E-mail)
Subject: [Cruisecontrol-user] Build loop hangs when jboss isn't stopped

Hello,
 
I am encountering a very annoying problem. 
 
Here is a short resume of what the build that cruisecontrol launches does:
 
- compile
- compile tests
- stop jboss (in case still running)
- launch jboss
- run tests
- stop jboss
If the tests fail during the build, cruisecontrol hangs.  It is waiting for jboss to be shutdown but the build doesn't reach the shutdown of jboss since it fails before.  If I manually kill the appserver (when it is hung) it will resume and complete successfully.
 

If I launch this task manually (eg: ant -f build-SAGE.xml -Dbuild.properties.file=../sage.properties") everything is fine and the build completes (fails but completes) even though jboss is still running.

Why does it hang when launched from cruisecontrol? How can I avoid this?
 
Thank you,
 
François
 
PS: Here is the command in the config.xml of cruisecontrol:
 
            <ant buildfile="build-SAGE.xml"
                 target="all"
                 uselogger="true"
                 usedebug="false"
                 antscript="C:\Java\ant\bin\ant.bat">
                <property name="build.properties.file" value="../sage.properties"/>
            </ant>
 
<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise