• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to use Xalan under WebLogic5.1

 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,
I've done a little program, which can translate XML to WML using Xalan API. But when tried to port the code to a servlet. It can't work. Weblogic gives me some runtime error. Looks like Weblogic can't work properly with Xalan XSLT.
The error message is as following:java.lang.NoSuchMethodError: org.w3c.dom.Node: method isSupported(Ljava/lang/Str
ing;Ljava/lang/String Z not found
at org.apache.xpath.axes.ChildWalkerMultiStep.getNextNode(ChildWalkerMul
tiStep.java, Compiled Code)
at org.apache.xpath.axes.ChildWalkerMultiStep.nextNode(ChildWalkerMultiS
tep.java, Compiled Code)
at org.apache.xpath.axes.LocPathIterator.nextNode(LocPathIterator.java:6
89)
at org.apache.xalan.templates.ElemValueOf.execute(ElemValueOf.java:255)
at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(Tr
ansformerImpl.java, Compiled Code)
at org.apache.xalan.transformer.TransformerImpl.transformToString(Transf
ormerImpl.java:1925)
at org.apache.xalan.templates.ElemAttribute.constructNode(ElemAttribute.
java:232)
at org.apache.xalan.templates.ElemElement.execute(ElemElement.java:354)
at org.apache.xalan.templates.ElemAttribute.execute(ElemAttribute.java:1
45)
at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(Tr
ansformerImpl.java, Compiled Code)
at org.apache.xalan.templates.ElemElement.constructNode(ElemElement.java
:400)
at org.apache.xalan.templates.ElemElement.execute(ElemElement.java:354)
at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(Tr
ansformerImpl.java, Compiled Code)
at org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResul
t.java, Compiled Code)
at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(Tr
ansformerImpl.java, Compiled Code)
at org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResul
t.java, Compiled Code)
at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(Tr
ansformerImpl.java, Compiled Code)
at org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResul
t.java, Compiled Code)
at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(Tr
ansformerImpl.java, Compiled Code)
at org.apache.xalan.templates.ElemLiteralResult.execute(ElemLiteralResul
t.java, Compiled Code)
at org.apache.xalan.transformer.TransformerImpl.executeChildTemplates(Tr
ansformerImpl.java, Compiled Code)
at org.apache.xalan.transformer.TransformerImpl.applyTemplateToNode(Tran
sformerImpl.java:2085)
at org.apache.xalan.transformer.TransformerImpl.transformNode(Transforme
rImpl.java, Compiled Code)
at org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java
:2942)
at java.lang.Thread.run(Thread.java:479)
Has anyone done similar program, which can work under Weblogic. Is there any setting I've missed out, ie classpath or system property..
Thanks and Regards
Waldle
 
Ranch Hand
Posts: 92
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't know which version of weblogic are u using. I used 5.1 and it does suppose most current jaxp package. Xalan may be the same case.
The way I did was unjar the package under default servletservlet directory for it to work with jsp. you should include the package before weblogicaux.jar in property file (because weblogicaux.jar has some xml stuff). That may not be the best solution, but I can't seem to find anything else. If you found something better, please let me know.
 
Waldle Cai
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
yup, you're right.after i changed the classpath so that Xalan jar files are before the Weblogicaux.jar. it works!!!
Thanks a lot
Waldle
 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I noticed that instead of the apache xalan packages, there are weblogic supplied versions e.g.
weblogic.apache.xalan.xslt
instead of
org.apache.xalan.xslt
When I used these, things went sweet.
 
Look! It's Leonardo da Vinci! And he brought a tiny ad!
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic