ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject How to deal with RuntimeExceptions thrown by tasks?
Date Fri, 04 Jun 2004 08:53:48 GMT
I'm not sure I'm really able to capture the issue completely but I'll
try.  The discussion so far has been around <ant> and friends, but
maybe there is something deeper.

The code that handles the keepGoing mode explicitly only handles
BuildExceptions - all other exceptions cause Ant to abort immediately.

The questions I've seen so far:

* should Ant continue in the presence of other RuntimeExceptions if
  keepGoing is set?

* or simply wrap any other RuntimeException into a BuildException?

* maybe even do this in Task#perform so that no RuntimeException ever
  propagates outside of the Task execution?

  This may need to be done in Target#performTasks or even
  Target#execute once again since tasks can override perform.

* should Ant do this with all RuntimeExceptions or exclude some where
  continuing may be wrong (SecurityException for example?)

Stefan

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


Mime
View raw message