Tuesday, June 05, 2007

failed to create an XPathFactory

In case you get this error someday:
java.lang.RuntimeException: XPathFactory#newInstance() failed to create an XPathFactory for the default object model: http://java.sun.com/jaxp/xpath/dom with the XPathFactoryConfigurationException: javax.xml.xpath.XPathFactoryConfigurationException: No XPathFctory implementation found for the object model: http://java.sun.com/jaxp/xpath/dom
using tomcat5.5 and JAXP, remember to look at
and delete symlinks/files in the directory:

xercesImpl.jar -> ../../../java/xercesImpl.jar
xml-apis.jar -> ../../../java/xml-apis.jar

Took me 2 hours to find out. Perhaps it will help someone.


Martin said...

Just helped me a great deal - thanks!

Michael Economy said...

Thanks! This fixed my problem also!!!