Return-Path: Mailing-List: contact ant-dev-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list ant-dev@jakarta.apache.org Received: (qmail 93841 invoked from network); 9 Aug 2000 01:30:20 -0000 Received: from smtp02.mrf.mail.rcn.net (207.172.4.61) by locus.apache.org with SMTP; 9 Aug 2000 01:30:20 -0000 Received: from r83aap006110.sbo.ma.cable.rcn.com ([209.6.196.75] helo=cow) by smtp02.mrf.mail.rcn.net with smtp (Exim 3.15 #2) id 13MKhH-0006l5-00 for ant-dev@jakarta.apache.org; Tue, 08 Aug 2000 21:30:19 -0400 From: "Tim Fennell" To: Subject: RE: Weblogic 5.1.0, xml4j and jaxp won't play nice... Date: Tue, 8 Aug 2000 21:29:42 -0400 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Importance: Normal In-Reply-To: <399081E3.75D91FA9@expressaction.com> X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N I've come up against this too, and concurr. It should work fine if you put the weblogic jars/dirs in the classpath ahead of parser.jar. It would appear that WebLogic's tools request a jaxp compliant parser, but then try to downcast some of the DOM objects returned to more specific classes. The downcast only works with the xml4j parser. Tsk tsk. -t -----Original Message----- From: Rod McChesney [mailto:rodm@expressaction.com] Sent: Tuesday, August 08, 2000 17:56 To: ant-dev@jakarta.apache.org Subject: Re: Weblogic 5.1.0, xml4j and jaxp won't play nice... Did you try putting the WebLogic stuff first on the classpath? We're doing this here (I just switched over to ant 3 days ago) and it works OK despite the potential conflict. Rod Scott Sutherland wrote: > > I've been attempting to automate the creation of deployable jar files > for EJB's used by our current project and have run into a situation > where weblogic and jaxp won't play nice together. > > If anyone has experienced the following and developed a ant based > work-around I would greatly appreciate hearing your solution... > > The problem manifests itself as a ClassCastException when > weblogic.ejbc is executing on the 'generic' jar file. > > Here are the actual exception and stack trace: > > AccountBean: > [javac] Compiling 3 source files to D:\usr\src\pd2.1\AccountEJB\classes > [copydir] Copying 2 files to D:\usr\src\pd2.1\AccountEJB\classes\META-INF > [jar] Building jar: D:\usr\src\pd2.1\AccountEJB\account-generic.jar > java.lang.ClassCastException: com.sun.xml.tree.TextNode > at weblogic.xml.dom.DOMUtils.getOptionalElementsByTagName(DOMUtils.java:204) > at weblogic.xml.dom.DOMUtils.getOptionalElementByTagName(DOMUtils.java:170) > at weblogic.xml.dom.DOMUtils.getOptionalValueByTagName(DOMUtils.java:97) > at weblogic.ejb.deployment.dd.EJBReadDOM.getDescriptionValue(EJBReadDOM.java:404) > at weblogic.ejb.deployment.dd.DescriptorLoader.createDeploymentUnit(DescriptorLoade r.java:200) > at weblogic.ejbc.runBody(ejbc.java:299) > at weblogic.utils.compiler.Tool.run(Tool.java:80) > at weblogic.ejbc.main(ejbc.java:353) > at java.lang.reflect.Method.invoke(Native Method) > at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:97) > at org.apache.tools.ant.taskdefs.Java.run(Java.java:243) > at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:123) > at org.apache.tools.ant.taskdefs.Java.execute(Java.java:90) > at org.apache.tools.ant.Target.execute(Target.java:132) > at org.apache.tools.ant.Project.runTarget(Project.java:720) > at org.apache.tools.ant.Project.executeTarget(Project.java:451) > at org.apache.tools.ant.Project.executeTargets(Project.java:425) > at org.apache.tools.ant.Main.runBuild(Main.java:298) > at org.apache.tools.ant.Main.main(Main.java:119) > ERROR: java.lang.ClassCastException: com.sun.xml.tree.TextNode > > The problem is associated with conflicts between JAXP and xml4j... I > can execute weblogic.ejbc from the command line if I change the class > path to exclude JAXP jars, but then ant will not run until I add them > back. > > Thanks in advance, > > Scott > > -- > Scott Sutherland National Computer Systems > (319) 354-9200 Measurement Services Division > suthsc@ncs.com Iowa City, Ia > import my.standard.disclaimer.*; GO HAWKS!!! > > "Coding in windows is sort of like writing a biography about a > person who won't tell you anything about themselves." - jheart8