You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by "Melzer, Steven" <St...@paymentech.com> on 2004/01/09 20:54:25 UTC

Custom task cannot see classpath

under ant 1.5.x i created a custom task that did some work with weblogic.  i included the weblogic.jar in the ANT_HOME/lib directory and all worked well.

i upgraded to ant 1.6.0 yesterday, put the weblogic.jar in the ANT_HOME/lib dreictory and my custom task started failing with a ClassNotFoundException because it could not find a class from the weblogic.jar package.

i understand now that the classpath isn't "assembled" in the batch script, but rather by the class loader within the Launcher class within Ant.  however, why doesn't my custom task see that class?  is it using a different class loader for custom tasks?  how do i get my custom task to see the weblogic jar?

thanks,
steve 
  
Learn more about Paymentech's payment processing services at www.paymentech.com
THIS MESSAGE IS CONFIDENTIAL.  This e-mail message and any attachments are proprietary and confidential information intended only for the use of the recipient(s) named above.  If you are not the intended recipient, you may not print, distribute, or copy this message or any attachments.  If you have received this communication in error, please notify the sender by return e-mail and delete this message and any attachments from your computer.

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


Re: Custom task cannot see classpath

Posted by Stefan Bodewig <bo...@apache.org>.
On Fri, 9 Jan 2004, Steven Melzer <St...@paymentech.com>
wrote:

> i understand now that the classpath isn't "assembled" in the batch
> script, but rather by the class loader within the Launcher class
> within Ant.  however, why doesn't my custom task see that class?  is
> it using a different class loader for custom tasks?

Probably yes (if you are using a custom classpath in your <taskdef>).

> how do i get my custom task to see the weblogic jar?

What does your taskdef look like?

Why do you put weblogic.jar into ANT_HOME/lib but not the jar
containing your custom task?

Stefan

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