Opened 13 years ago
Closed 13 years ago
#841 closed defect (fixed)
Data dir changes cause error on Windows
Reported by: | heikki | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | v2.7.0 |
Component: | General | Version: | |
Keywords: | Cc: |
Description
Since the change with datadir, on Windows you get lots of errors in the console about files not found - the application directory path is duplicated (see below).
Possibly this is because the generated schemaplugin-uri.xml contains a file separator too many:
C:\_qx\web\geonetwork/WEB-INF/data/\config\schema_plugins/iso19139.geobru/present/metadata-iso19139.geobru-edit.xsl
<error id="error"> <message>C:\_______qx\web\geonetwork\C:\_______qx\web\geonetwork\WEB-INF\data\config\schema_plugins\iso19139.geobru\loc\eng\labels.xml (The filename, directory name, or volume label syntax is incorrect)</message> <class>FileNotFoundException</class> <stack> <at class="java.io.FileInputStream" file="???" line="-2" method="open" /> <at class="java.io.FileInputStream" file="???" line="-1" method="<init>" /> <at class="java.io.FileInputStream" file="???" line="-1" method="<init>" /> <at class="sun.net.www.protocol.file.FileURLConnection" file="???" line="-1" method="connect" /> <at class="sun.net.www.protocol.file.FileURLConnection" file="???" line="-1" method="getInputStream" /> <at class="org.apache.xerces.impl.XMLEntityManager" file="???" line="-1" method="setupCurrentEntity" /> <at class="org.apache.xerces.impl.XMLVersionDetector" file="???" line="-1" method="determineDocVersion" /> <at class="org.apache.xerces.parsers.XML11Configuration" file="???" line="-1" method="parse" /> <at class="org.apache.xerces.parsers.XML11Configuration" file="???" line="-1" method="parse" /> <at class="org.apache.xerces.parsers.XMLParser" file="???" line="-1" method="parse" /> <skip>...</skip> <at class="jeeves.utils.Xml" file="Xml.java" line="219" method="loadFile" /> <at class="jeeves.utils.XmlFileCacher" file="XmlFileCacher.java" line="122" method="load" /> <at class="jeeves.utils.XmlFileCacher" file="XmlFileCacher.java" line="84" method="get" /> <at class="jeeves.server.dispatchers.guiservices.XmlFile" file="XmlFile.java" line="109" method="exec" /> <at class="org.fao.geonet.services.schema.Info" file="Info.java" line="171" method="getHelp" /> <at class="org.fao.geonet.services.schema.Info" file="Info.java" line="156" method="handleObject" /> <at class="org.fao.geonet.services.schema.Info" file="Info.java" line="124" method="handleElement" /> <at class="org.fao.geonet.services.schema.Info" file="Info.java" line="105" method="exec" /> <at class="jeeves.server.dispatchers.ServiceInfo" file="ServiceInfo.java" line="230" method="execService" /> <at class="jeeves.server.dispatchers.ServiceInfo" file="ServiceInfo.java" line="139" method="execServices" /> <at class="jeeves.server.dispatchers.ServiceManager" file="ServiceManager.java" line="411" method="dispatch" /> <at class="jeeves.server.JeevesEngine" file="JeevesEngine.java" line="723" method="dispatch" /> <at class="jeeves.server.sources.http.JeevesServlet" file="JeevesServlet.java" line="196" method="execute" /> <at class="jeeves.server.sources.http.JeevesServlet" file="JeevesServlet.java" line="110" method="doPost" /> <skip>...</skip> </stack> <request> <language>fre</language> <service>xml.schema.info</service> </request> </error>
Note:
See TracTickets
for help on using tickets.
Error is related to data dir changes, as now using full paths in some places.
The following code in XmlFile class (jeeves) caused the issue. This code seem assumes full paths start with / , not very generic.
Changed to:
seem working fine.
Committed in revision 8924