- Timestamp:
- 2010-07-13T17:08:22+12:00 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone3/src/java/org/greenstone/gsdl3/util/XMLTransformer.java
r22370 r22390 74 74 */ 75 75 public XMLTransformer() { 76 // make sure we are using the xalan transformer77 78 76 // http://download.oracle.com/docs/cd/E17476_01/javase/1.5.0/docs/api/index.html?javax/xml/transform/TransformerFactory.html states that 79 77 // TransformerFactory.newInstance() looks in jar files for a Factory specified in META-INF/services/javax.xml.transform.TransformerFactory, … … 84 82 // This means we no longer have to do a System.setProperty("javax.xml.transform.TransformerFactory", "org.apache.xalan.processor.TransformerFactoryImpl"); 85 83 // followed by a this.t_factory = org.apache.xalan.processor.TransformerFactoryImpl.newInstance(); 86 // The System.setProperty step to force the TransformerFactory implementation that gets used conflicts with84 // The System.setProperty step to force the TransformerFactory implementation that gets used, conflicts with 87 85 // Fedora (visiting the Greenstone server pages breaks the Greenstone-tomcat hosted Fedora pages) as Fedora 88 86 // does not include the xalan.jar and therefore can't then find the xalan TransformerFactory explicitly set. 89 87 88 // Gone back to forcing use of xalan transformer, since other jars like crimson.jar, which may be on some 89 // classpaths, could be be chosen as the TransformerFactory implementation over xalan. This is what used to 90 // give problems before. Instead, have placed copies of the jars that Fedora needs (xalan.jar and serializer.jar 91 // and the related xsltc.jar which it may need) into packages/tomcat/lib so that it's on the server's classpath 92 // and will be found by Fedora. 93 94 // make sure we are using the xalan transformer 95 System.setProperty("javax.xml.transform.TransformerFactory", "org.apache.xalan.processor.TransformerFactoryImpl"); 90 96 try { 91 this.t_factory = TransformerFactory.newInstance(); 97 this.t_factory = org.apache.xalan.processor.TransformerFactoryImpl.newInstance(); 98 //this.t_factory = TransformerFactory.newInstance(); 92 99 } catch (Exception e) { 93 100 logger.error("exception "+e.getMessage());
Note:
See TracChangeset
for help on using the changeset viewer.