DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=18543>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=18543

Cannot work with j2ee1.3.1.jar

           Summary: Cannot work with j2ee1.3.1.jar
           Product: Ant
           Version: 1.5.2
          Platform: PC
        OS/Version: Windows NT/2K
            Status: UNCONFIRMED
          Severity: Normal
          Priority: Other
         Component: Core
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


In our software, we use j2sdkee1.3.1. Because in j2ee1.3.1.jar there exists
org.w3c.dom.* and org.xml.sax.*, so when I run junit task there always report
an error: 
java.lang.LinkageError: loader constraints violated when linking 
org/w3c/dom/Document class
        at org.apache.crimson.jaxp.DocumentBuilderFactoryImpl.newDocumentBuilder
(DocumentBuilderFactoryImpl.java:82)
        at 
org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter.getDocument
Builder(XMLJUnitResultFormatter.java:93)
        at 
org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter.startTestSu
ite(XMLJUnitResultFormatter.java:138)
        at 
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.fireStartTestSuite
(JUnitTestRunner.java:445)
        at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run
(JUnitTestRunner.java:279)
        at org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.executeInVM
(JUnitTask.java:848)
        at org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute
(JUnitTask.java:556)
        at org.apache.tools.ant.taskdefs.optional.junit.JUnitTask.execute
(JUnitTask.java:532)
        at org.apache.tools.ant.Task.perform(Task.java:341)
        at org.apache.tools.ant.Target.execute(Target.java:309)
        at org.apache.tools.ant.Target.performTasks(Target.java:336)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1339)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1255)
        at org.apache.tools.ant.Main.runBuild(Main.java:609)
        at org.apache.tools.ant.Main.start(Main.java:196)
        at org.apache.tools.ant.Main.main(Main.java:235)
If I use j2ee1.3.1.jar to replace the ${ANT_HOME}/lib/xml-apis.jar, the ant 
cann't run.
But I must use j2ee1.3.1.jar for some other functions.
I have change the includeantruntime attibute of <junit>, but it does not work.
From the docs, I think it should work to use j2ee1.3.1.jar and ignore xml-
apis.jar.

If I delete org.w3c.dom.* from j2ee1.3.1.jar, it work. But it is apparently a 
bad method. 

How to resolve it?

Thanks!

Reply via email to