Project

General

Profile

Bug #7867

The resource element can't be added to the solr index of an object if it is obsoletedBy

Added by Jing Tao over 8 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
d1_indexer
Target version:
Start date:
2016-08-16
Due date:
% Done:

100%

Milestone:
None
Product Version:
*
Story Points:
Sprint:

Description

If an object was obsoleted by another object and it is aggregated in a resource map, the resource map element can't be added to the obsoletedBy object when we index the resource map. I think this is a bug. The resourceMap element should be added to the solr index of the object even though the object is obsoleted by another object.

History

#1 Updated by Jing Tao over 8 years ago

This is caused by the method _mergeMappedReference in the class src/main/java/org/dataone/cn/indexer/resourcemap/ForesiteResourceMap.java in d1_cn_index_processor component. In this method, it check a condition - if the referenced object has the obsoletedBy element. If it does, the merge will be skipped ( the resourceMap solr element wouldn't be added to the solr index of the referenced object).

I can imagine this is for the series id. In this scenario - a resource map "foo" aggregates series id "S". We always want to only the head pid of series chain has the resource map solr element. So we need to check. However, the code doesn't check the series id in the system metadata; instead, it checks the obsoletedBy element. This caused the issue.

The condition was changed to - if the object is in the series chain and the object is not the head version, the merge will be skipped.

#2 Updated by Jing Tao over 8 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

The fixed code was committed to both trunk and D1_CN_INDEX_PROCESSOR_v.2.2 branch

#3 Updated by Jing Tao over 8 years ago

Created the tag D1_CN_INDEX_PROCESSOR_v2.2.1 for this fix.

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 14.8 MB)