Code Robo
Formatter
Comparator
Tester
Merger
Converter
Utility
Java Code Complience
Validator
EncoderDecoder
Virtual Service
XPathFactory#newInstance() failed to create an XPathFactory for the default object model:
       Talk to EasyAssistant

javax.xml.xpath.XPathFactoryConfigurationException: java.util.ServiceConfigurationError: javax.xml.xpath.XPathFactory: jar:file: Illegal configuration-file syntax..

This page tells you how to solve the 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: when you are trying to evaluate an XPath. This issue is happeing from JDK 1.8.0_362 onwards. It was working fine with older version of JDK and with Saxon 9.5. Now with Higer version of JDK its throwing exception for xpath evaluation.
Exception:
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: 
java.util.ServiceConfigurationError: javax.xml.xpath.XPathFactory: jar:file: 
Illegal configuration-file syntax


Solution:
Download Saxon-HE-9.8.x or higher and add it to your project class path or bundle it with your ear file. It should fix the issue.


Post Your Comment:
Name :
Email ( Optional) :
Comments / Suggestion (* Required) It is required: :
: