File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes BEA/Weblogic and the fly likes How to resolve conflict between XALAN and SUN trasformer Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "How to resolve conflict between XALAN and SUN trasformer" Watch "How to resolve conflict between XALAN and SUN trasformer" New topic
Author

How to resolve conflict between XALAN and SUN trasformer

Anish Kuti
Greenhorn

Joined: May 12, 2008
Posts: 29
In my weblogic domain , 2 application is deployed .

1st Application - has a code which do XSLT transformation using XALAN .For this below preference is set in code
system.setproperty("javax.xml.transform.TransformerFactory" ,"org.apache.xalan.processor.TransformerFactoryImpl")

2nd Application - has code which has XSLT tranformer .. but it does not use XALAN .. it use simple SUN java transformer.

But when we deployed the both application in the same weblogic domains .. it does conflict.. 2 nd application ask for XALAN transformer to set .. which is not required for this 2 nd application .. How to solve this kind of conflict ? Any help will be appreciated.
Ed Ward
Ranch Hand

Joined: Jan 30, 2006
Posts: 147
Not sure if this will work, but for the app that uses xalan, try this:

1. Build that library into the archive.
2. Use a weblogic.xml descriptor with these elements (of course you lose portability):

2. Remove the system.setproperty call. If these apps are deployed to the same managed server then I think this is part your problem.

You may need to bounce the server in order to clear out any xalan class instances.

Anyone else feel to correct me, like I said I don't know if this will work.

Just curious though, why would you not settle on one XSLT transformer within a single JVM?
Anish Kuti
Greenhorn

Joined: May 12, 2008
Posts: 29
Thanks for your help !! .. I will try this and let you know it works..

"Just curious though, why would you not settle on one XSLT transformer within a single JVM? "
.. .. actually we were testing two application in a Development env and it has only one JVM..it would not happen in case of production.
 
 
subject: How to resolve conflict between XALAN and SUN trasformer