ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Linas Jakucionis" <>
Subject multiple definion of taskdef loads the same libraries again?
Date Wed, 12 Mar 2003 14:12:24 GMT

I am not really sure, but it seems to me, that multiple taskdef tries to redefine the task

that is already defined and loads the same libraries again without releasing the 
memory that was used for old definition...

The situation I have is the following:
1. I have build1.xml which defines taskdef ejbdocklet
2. I have another build2.xml which has to use ejbdocklet task also, so I have taskdef 
ejbdocklet in this file also.
3. The problem is that I have to call build1.xml:
a) separately
b) a lot of times from inside build2.xml

If I have task definition of ejbdocklet inside of build2.xml only, I can call build1.xml from

inside of build2.xml and everything works fine, but I cannot run  build1.xml separately.

If I have task definition of ejbdocklet in both files, build1.xml works fine, but when 
running it multiple times using <ant> from inside of build2.xml the ant crashes with

either message:

Exception in thread "main"

or messages stating that Java ran out of memory... (Sorry, I cannot quote the exact 
message now)

Is there any possibility to tell ant not to define task with taskdef if the task has already

been defined?

Do you have any suggestions about this?


View raw message