ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ckn...@onebox.com
Subject How to get debug info on java task failure
Date Thu, 28 Sep 2006 16:49:17 GMT
I am executing a single <java> task. I have the failonerror attribute set to "true".
It fails, but I don't have any information to work with. This is the target.

<target name="fetch-sql-string">
  <java classname="com.surreylane.oracle.SQLQueryText" 
           outputproperty="sql.string" 
           failonerror="true" fork="true">
    <classpath>
      <pathelement location="./XMLfromSPOOL/mars.jar" />
      <pathelement location="c:/oracle/ora90JavaXDK/lib/xsu12.jar" />
      <pathelement location="c:/oracle/ora90JavaXDK/lib/xmlparserv2.jar" />
    </classpath>
    <arg value="QueryFileName=queries.xml" />
    <arg value="QueryName=hiring-report" />
  </java>
  <echo>SQL string is ${sql.string}</echo>
</target>

The output I get is: "BUILD FAILED H:\dev\java\buildj.xml:46: Java returned: 1"

When I execute what I believe to be the identical class from the command line, I have no problem.
Here is the command line, reformatted for clarity:

java -cp mars.jar;C:\oracle\ora90JavaXDK\lib\xsu12.jar;
c:\oracle\ora90JavaXDK\lib\xmlparserv2.jar 
com.surreylane.oracle.SQLQueryText QueryFileName=../queries.xml QueryName=hiring-report

How can I get more information from Ant on exactly what's gone wrong?

Thanks.
-- 
Charles Knell
cknell@onebox.com - email

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message