0 Replies Latest reply on Jul 6, 2012 6:14 AM by 938607

    Replace oracle jaxp implementation with xerces

    938607
      I am using Weblogic 10.3.6 and JDeveloper.

      I have tried to replace the oracle implementation of jaxp with xerces.
      This is because I think that dozer needs xerces instead of the oracle implementation of jaxp.
      I have done it with configuring
      <prefer-web-inf-classes>true</prefer-web-inf-classes>
      in WEB-INF/weblogic.xml and with adding the xerces libraries to the libraries wich are deployed.

      But if I try to replace the libraries I receive following exception while deploying the application.
      I have tried xerces 2.11.0 (jaxp 1.4) and also xerces 2.9.1 (jaxp 1.3, which should be the right replacement for Weblogic 10.3.6). (xercesImpl.jar, xml-apis.jar)

      Caused By: java.lang.NoSuchMethodError: org.apache.xerces.impl.xpath.regex.RegularExpression.<init>(Ljava/lang/String;Ljava/lang/String;Ljava/util/Locale;)V
           at org.apache.xerces.impl.dv.xs.XSSimpleTypeDecl.applyFacets(Unknown Source)
           at org.apache.xerces.impl.dv.xs.XSSimpleTypeDecl.applyFacets1(Unknown Source)
           at org.apache.xerces.impl.dv.xs.BaseSchemaDVFactory.createBuiltInTypes(Unknown Source)
           at org.apache.xerces.impl.dv.xs.SchemaDVFactoryImpl.createBuiltInTypes(Unknown Source)
           at org.apache.xerces.impl.dv.xs.SchemaDVFactoryImpl.<clinit>(Unknown Source)
           Truncated. see log file for complete stacktrace

      If you look in the sourcecode of org.apache.xerces.impl.xpath.regex.RegularExpression you will see that

      RegularExpression has following ctors in version 2.11.0:
      (String a)
      (String b, String d)
      (String c, String f, Locale l)
      (String d, Token t, int p, boolean h, int o)

      RegularExpression has following ctors in version 2.9.1:
      (String a)
      (String b, String d)
      (String c, Token t, int p, boolean h, int o)

      So I can´t unterstand why the exception occurs for both versions.


      Thanks.