I've been having issues for quite some time with some custom xdoclet
tasks I've written.  The custom tasks I have are packaged in a separate
jar from xdoclet and contain an xdoclet.xml file.  It works fine when
the initial generation happens.  However, if the subtask is run again, I
get failures in the template.

The impression I get is that something is determining that the
generation does not need to be done again and is eliminating the classes
from lookup, but the template is being evaluated anyway.  This is where
things fail.  In the the template, I'm calling a custom tags handler but
it is failing with a class not found exception.  Actually, I think this
is happening in the tagdef.  I can get around this by setting
force="true" in the parent task, but I'd rather not generate every time
the build runs.  I've since implemented some updtodate checks with ant
so I don't call the task if I don't have to, but that's a lot of ugly
handling that I have to duplicate everywhere I'm using custom tasks.  

In my build script, I have a task that first compiles the xdoclet code
and packages it up in a jar.  In a subsequent task, I'm incorporating
this jar in a classpath definition for a taskdef for my custom task.
This works fine when code generation actually needs to happen (like the
first time).

The only thing I can come up with is that there are issues with class
loading.  I haven't found any decent information in the archives about
this issue and haven't received any feedback to my earlier inquiries.
I've been trying to sift through the source but am having a hard time
figuring out what the deal is.  I'm wondering if appending classpath
information to the ModulesFinder will help.  I can't imagine every
custom task implementation works like this.  Can anyone shed any light
on why this is happening?  Anybody out there have any custom tasks
they've created that don't have this issue?

Thanks,

Scott



-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
_______________________________________________
xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to