I'm running ant 1.4.1 on W2000, and I have a "gateway" class which reads a
.properties file for classpath info (%CLASSPATH% is empty). The jar files
included for the classpath are exactly those required by ant 1.4.1. A
custom ClassLoader uses this info to load and launch ant. Thanks to
Vlad's response to an earlier request for help, I am now able to launch
ant successfully.
However, the following error appears that when ant is parsing my build.xml
file:
javax.xml.parsers.FactoryConfigurationError: Provider
org.apache.crimson.jaxp.SAXParserFactoryImpl not found
at
javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:105)
at
org.apache.tools.ant.ProjectHelper.getParserFactory(ProjectHelper.java:776)
at org.apache.tools.ant.ProjectHelper.parse(ProjectHelper.java:105)
at
org.apache.tools.ant.ProjectHelper.configureProject(ProjectHelper.java:85)
at org.apache.tools.ant.Main.runBuild(Main.java:439)
at org.apache.tools.ant.Main.start(Main.java:153)
at java.lang.reflect.Method.invoke(Native Method)
at AntTester.run(AntTester.java:99)
at AntTester.main(AntTester.java:248)
Based on some logged output from my custom ClassLoader, it appears that
javax.xml.parsers.FactoryFinder is using its own custom ClassLoader to load
SAXParserFactoryImpl, and that this ClassLoader knows nothing about my
custom ClassLoader. Hence it's looking for SAXParserFactoryImpl in the
%CLASSPATH%, which of course contains nothing useful. I tried researching
the javadoc for javax.xml.parsers.FactoryFinder, but found nothing.
Does anyone know whether my guess about the error is correct? And if it
is, is there anything I can do about it, other than bugging Sun to modify
javax.xml.parsers.FactoryFinder to be aware of the ClassLoader which
loaded it?
Thanks,
--dave
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>