Opened 13 years ago
Closed 13 years ago
#775 closed defect (fixed)
Uploaded Plugin Profile does not work
Reported by: | heikki | Owned by: | |
---|---|---|---|
Priority: | blocker | Milestone: | v2.7.0 |
Component: | General | Version: | |
Keywords: | plugin profiles schema | Cc: |
Description
I have a Plugin Profile that works fine if I manually put it in web/geonetwork/xml/schemas before starting GeoNetwork.
But it doesn't work when you upload it:
- I made a zip file of it and uploaded that; it got unzipped in web/geonetwork/schemaPlugins
- the profile was listed in the admin page, where I could successfully load the templates from my profile
- going to New Metadata, the names of the templates of this profile are not displayed (Ext GUI);
- selecting one and trying to create a metadata from it fails, because it tries to load XSLTs from its base ISO19139 schema from the web/geonetwork/schemaPlugins directory (where they aren't) instead of from the web/geonetwork/xml/schemas directory:
Error at xsl:include on line 7 column 57 of update-fixed-info.xsl: XTSE0165: java.io.FileNotFoundException: /web/geonetwork/schemaPlugins/iso19139/convert/functions.xsl (The system cannot find the path specified)
- schemaplugin-uri-catalog.xml *was* updated with lines like
<uri name="blanks/metadata-schema07.xsl" uri="../xml/schemas/iso19139.myprofile/present/metadata-iso19139.myprofile.xsl" /> <uri name="blanks/metadata-schema07-edit.xsl" uri="../xml/schemas/iso19139.myprofile/present/metadata-iso19139.myprofile-edit.xsl" />
- finally I tried manually moving the profile directory from web/geonetwork/schemaPlugins to web/geonetwork/xml/schemas, and restart. Now the home page doesn't show up anymore because it is looking for my profile in web/geonetwork/schemaPlugins:
Error at xsl:include on line 12 column 52 of metadata-utils.xsl: XTSE0165: java.io.FileNotFoundException: /web/geonetwork/schemaPlugins/iso19139.myprofile/present/metadata-iso19139.myprofile.xsl (The system cannot find the path specified)
So to summarize, it seems there is some confusion when a Plugin Profile is uploaded as to whether it is or should be in web/geonetwork/xml/schemas or in web/geonetwork/schemaPlugins.
Change History (5)
follow-up: 2 comment:1 by , 13 years ago
Keywords: | schema added |
---|
comment:2 by , 13 years ago
I referred to heikii for the error, but I meant taniapf on http://osgeo-org.1560.n6.nabble.com/personalized-schema-plugin-error-td4667319.html (sorry for the mixup).
Thus: I used schemaPlugin to create the iso19139.mcp-1.4.zip and iso19139.anzlic.zip and upload it via the administration page to GeoNetwork. After that, the TransformerConfigurationException appears.
Tried : I tried the same, but with the example files I downloaded with the schemaPlugin. I tried the schema iso19139.mcp-1.4 and iso19139.anzlic. The result for both of the example schemes are the same as described by heikki.
comment:3 by , 13 years ago
Actually this is a different bug to Heikki's original but it is fixed in svn rev 8955 - the bug you have found is restricted to cases where the schema is uploaded as a zip file - it was triggered during changes for geonetwork data dir.
(Also note that iso19139.mcp-1.4 depends on iso19139.mcp - you need to upload both schemas for these to work).
comment:4 by , 13 years ago
Confirm. The problem I had is indeed fixed with the new revision. I had revision 8948 or so, one or two days before the 8955.
comment:5 by , 13 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Re-jig the schemamanager design to remove the distinction between plugin and built in schemas - all schemas can be plugged in now and they all live in the same place - the data directory(specifically data/config/schema_plugins).
See svn rev 8986
Tried : I tried the same, but with the example files I downloaded with the schemaPlugin. I tried the schema iso19139.mcp-1.4 and iso19139.anzlic. The result for both of the example schemes are the same as described by heikki.
Before uploading a schema, GeoNetwork "works". After uploading a schema, GeoNetwork doesn't do anything any more, except showing the error on every page, not only the admin page.
Noticed : I also took a look on the location of the uploaded schema. In my case (I run the geonetwork.war under tomcat), this seems to be:
Which is awkward (the part of the usr/share/tomcat6/webapp/geonetwork path is double!).
Undo : To get geonetwork working again, I have to delete the whole geonetwork dir under tomcat and redeploy the war (thus throwing away all data caused by the upload of the schema).
Exception : Here I put the exception from the geonetwork.log. It seems it isn't looking at the place where the schema has been put (see the awkward path above) and, there seems to be a slash missing in the path, I see "schema_pluginsiso19139.mcp-1.4" in the path in the logging.