-
Notifications
You must be signed in to change notification settings - Fork 0
How schemas work in GeoNetwork
Jo Cook edited this page Jan 29, 2021
·
1 revision
- Schemas are installed in the folder indicated by "Standard folder:" in Admin Console -> Statistics and Status -> Information, but also have to be registered in the GeoNetwork database, which is done by iterating through the above folder at start up.
- Depending on the schema, sometimes you can't get away with just copying files into the above folder. Instructions should be provided on how you install them, depending on whether you're building GeoNetwork from source or adding to an existing installation. See https://github.com/AstunTechnology/iso19139.gemini23 for install instructions for Gemini 2.3
- Generally the form of schemas in GitHub is to include the full path as if building from source. If applying to an existing installation then the folder you actually want to copy into the "Standard folder" is the
src/main/plugin/schemaname
folder, NOT the rootschemaname
folder. - Note also that you may need to choose a different branch of the schema repository for your version of GeoNetwork.
- See https://www.geonetwork-opensource.org/manuals/trunk/en/customizing-application/implementing-a-schema-plugin.html for more information but don't get bogged down in the details!
- If the schema was registered successfully then it will be visible in Admin Console -> Metadata and Templates
- GeoNetwork has to assign a record to a schema before you can validate it against the correct schematron. It uses the XML in the record to guess at this on import, so you need to define what XML is required for a record to be identified as your chosen schema. This is defined in the schema's
schema-ident.xml
file. See https://github.com/AstunTechnology/iso19139.gemini23/blob/3.10.x/src/main/plugin/iso19139.gemini23/schema-ident.xml for Gemini 2.3. - If GeoNetwork can't guess at the correct schema, then it will assign the default, which is generally ISO19139, although this can be set in the code to something different.
- Once GeoNetwork has decided on the schema it should use, this is entered in the
schemaid
column in thepublic.metadata
table. - It is this value, and this value only, that is used to determine which schematron are used for validation, and what editing interface to use.
- In the Contribute tab, in the list of search facets on the left, look for the entry "METADATA STANDARD" to filter records by loaded schema.
- As a quick check when editing a Gemini 2.3 record- the simple view shows advice below each entry- this is not present in ISO19139 or Gemini 2.2.