Menu

#99 trycatch task impact on the ANT XML log

v1.0 (example)
closed-fixed
nobody
logic (23)
5
2006-08-16
2004-07-08
Anonymous
No

Guys,
I have faced with the critical issue while using trycatch
task. Our company uses the CruiseControl 2.1.5 for
Continues Integration process, we are using the AntBuild
for Schedule, this Builder uses ANT with
org.apache.tools.ant.XmlLogger logger, there is no
another option for logger right now. Therefore there is
no workaround for using trycatch task.

I have embeded the test files content into message
body.

<<ant_contrib_try_catch_tasks.bat start>>
set old_path=%path%
set path=%path%;.\Ant\bin
echo be sure that Ant/Bin/ant.bat JAVA_HOME is set
properly
rem ant.bat -logfile
cc_masterbuild_prototype_ear_build.log -buildfile
full_prototype_ear_build.xml cc_masterbuild
ant -logger org.apache.tools.ant.XmlLogger -logfile
ant_contrib_try_catch_tasks.log.xml -buildfile
ant_contrib_try_catch_tasks.xml default
set path=%old_path%
<<ant_contrib_try_catch_tasks.bat end>>

<<ant script start here>>
<?xml version="1.0"?>
<project name="Build Serviceware.ear" default="default"
basedir=".">
<taskdef name="trycatch"
classname="net.sf.antcontrib.logic.TryCatchTask"/>
<target name="default" depends="init">
<echo>Start test script here</echo>
</target>

<target name="init" description="">
<trycatch>
<try>
<echo>init in try block</echo>
</try>
<catch>
<echo>init in catch block</echo>
</catch>
</trycatch>
</target>
</project>
<<ant script end here>>

<<result log start>>
<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="log.xsl"?>

<build time="1 second">
<task name="
<<result log end>>

Result log cannot be parsed.
Victor S.
mailto:shefbel@yahoo.com
EPAM, Lead Developer

Discussion

  • Matt Inger

    Matt Inger - 2006-08-16
    • status: open --> closed-fixed
     
  • Matt Inger

    Matt Inger - 2006-08-16

    Logged In: YES
    user_id=83032

    THis doesn't seem to be an issue anymore, closing as fixed.

     

Log in to post a comment.