wiki:MimeTypeCalculationIndexing

Version 2 (modified by simonp, 14 years ago) ( diff )

--

Mime Type Calculation and Indexing

Date 2010/04/14
Contact(s) Simon Pigot
Last edited Timestamp
Status Complete
Assigned to release 2.5.0
Resources Available

Overview

GeoNetwork uses all kinds of code in a few different places to calculate mime types for files that are uploaded with metadata records as online resources (usually based on filenames). However the mime type is never indexed with the metadata record that points to the resource and the mime type calculation is usually done based on the filename so may not reflect the true content of the file or return the correct registered mime type for alternatives filenames. This means that searches cannot be done on the content of online resources.

Proposal Type

  • Sandbox: BlueNetMEST
  • App: GeoNetwork
  • Module: Lucene Index, Metadata Schemas

Voting History

  • Vote proposed but voting not yet closed.

Motivations

The motivation for this proposal is to get the mime type into the Lucene index for use by other programs that may want to do searches via CSW to determine whether GeoNetwork has metadata records with attached online resources that could be of interest. The particular use case this was developed for is a data visualization program which wanted to search the GeoNetwork catalog for files of interest.

Proposal

This proposal implements:

  • Mime type calculation for online resources using mime-util immediately after a metadata record is saved/imported in update-fixed-info.xsl.
  • Indexing of the mime type in Lucene by index-fields.xsl

At this stage the proposal does not:

  • include adding a search field in the advanced search interface
  • replace mime type calculations done elsewhere (specifically in Jeeves src/jeeves/util/BinaryFile.java and in metadata-iso19139.xsl) in GeoNetwork with mime-util code or the results of mime-util

These can be done at a later date.

Risks

At present the only reasonable place for storing the mime type in the onlineresource field is as a uuid attribute of the gmd:linkage element. If an element/attribute is not used then the mime type will have to be calculated at the time of indexing - this may slow down indexing of many records with attached online resources.

Participants

  • CSIRO: Gary Carroll and Uwe Rosebrock

Attachments (1)

Download all attachments as: .zip

Note: See TracWiki for help on using the wiki.