I am trying to do continue integration w/ luntbuild and it requires ant to output "BUILD SUCCESS" or result==0 in order to declare the build is successful
The last step of my build is to start tomcat. I basically just use:
to start tomcat, here is the dilemma, if I dont use spawn="true" it will hang indefinately and luntbuild will eventually give up and declare build failed. On the other hand, if i use spawn="true" it will show build success, but the output is not actually logged (as per doucmentation in ant 1.7).
What can I really do for luntbuild to recognize that tomcat has started and be able to meet the success build condition. I appreciate any help guys, really stuck here
When you say "but the output is not actually logged", which output do you mean? The output from Tomcat? If so, here is the description of the exec spawn attribute from the Ant 1.7.1 manual:
spawn whether or not you want the command to be spawned
Default is false.
If you spawn a command, its output will not be logged by ant.
The input, output, error, and result property settings are not active when spawning a process.
since Ant 1.6
Maybe I should reword my question. I think by using spawn="true", luntbuild somehow doesn't recognize "BUILD SUCCESSFUL" that was output by Ant. I am wondering if there is a way to know that tomcat has succesfully started in Ant without using spawn="true", because basically what ant will do is just hangs until tomcat is shutdown, then it will output "BUILD SUCCESSFUL".
Did you ever find an answer to this problem? I am having a similar issue - I want Tomcat's startup to be logged to the console in Eclipse, and then after that I am executing a program, but the console output never finishes - I never see the "Build successful" message - I just see the Tomcat startup log - the rest of the ANT script doesn't go to the console.
Your question, while similar to the original poster's, is not the same. Please start a new topic. And when you do please post the Ant target in question and the last few lines of the output that you do see.
subject: Logging output with spawn="true" using exec