Bug 46121 - "resources" ant task clashes with ant 1.7 "resources" element
Summary: "resources" ant task clashes with ant 1.7 "resources" element
Status: RESOLVED FIXED
Alias: None
Product: Tomcat 6
Classification: Unclassified
Component: Manager application (show other bugs)
Version: unspecified
Hardware: PC Windows XP
: P2 minor (vote)
Target Milestone: default
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-29 08:30 UTC by Matt Wildig
Modified: 2017-04-20 20:25 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Matt Wildig 2008-10-29 08:30:43 UTC
Not sure if this counts as a bug, but I thought it needs mentioning.

The "resources" task described in antlib.xml in catalina-ant.jar conflicts with the resources element introduced in ant 1.7.

This results in ant reporting the message "Trying to override old definition of datatype resources", which may be the only effect if you're not using the ant resources (http://ant.apache.org/manual/CoreTypes/resources.html#collection).

It does have the potential to cause existing builds using these resources collections to fail if you then add the tomcat tasks using the antlib.xml.
Comment 1 Matt Wildig 2008-10-29 12:59:07 UTC
A little bit of thought and research into this and I realise the solution is of course to use ants namespace support. Perhaps all that's needed is a note in the documentation so people don't get caught out by this.
Comment 2 Mark Thomas 2008-11-03 15:51:31 UTC
Thanks for the report. this has been fixed in trunk and 6.0.x and will be in 6.0.19 onwards.
Comment 3 Jonathan Horowitz 2017-04-20 19:59:15 UTC
This is still happening for me with Ant 1.8 and Tomcat 8.5.11.

I went through the ASF SVN revisions around that time, and could not find anything regarding this issue.

Perhaps the fix was lost on a local dev machine and never committed?
Comment 4 Mark Thomas 2017-04-20 20:23:03 UTC
The minimum Ant version to build 8.5.x is 1.9.5 as documented in BUILDING.txt in the root of the directory.

Comment #3 is therefore INVALID but I am restoring the fix status for this issue.
Comment 5 Mark Thomas 2017-04-20 20:25:41 UTC
Ignore the 1.9.5 comment but the INVALID aspect stands. The need to use a namespace is documented in the Manager HowTo.