As an developer, I want to instantiate DC catalogs with intentionally emptied fields, so I can merge catalogs together and targeted fields to empty


[Edited for clarity]

As a developer, I want to merge targeted field updates into an existing (DublinCore or any) catalog, and leave the non-targeted fields intact. In other words, to "merge" a new catalog into an existing catalog and only modify targeted fields in the existing catalog. The focus of this ticket is the ability to target existing values in order to empty them of an existing value.

ISSUE: DublinCore Catalog objects does not instantiate "empty" fields from a source XML file, it only instantiates fields that contain a non-empty value.

SOLUTION: Add optional "includeEmptyValue" parameter on the org.opencastproject.metadata.api.CatalogService#load(, boolean) to optionally preserve "empty" fields in the source XML. The default will be "false", keeping the current behavior not instantiating empty value from the source XML into the catalog object.

TMI: Replacing a catalog with a new one (from a 3rd party system) can cause data loss if the updating system is unaware of all the values in the existing catalog. Merging just targeted updates, allows the source system to be blissfully unaware of all the fields being used in the catalog.


Former user


Former user



Tags (folksonomy)



Affects versions