Skip to content

Commit

Permalink
Indexing / Lower severity of getIndexField
Browse files Browse the repository at this point in the history
While indexing, a number of log error can be reported:
```
2024-06-18T17:11:21,679 ERROR [geonetwork] - Failed to get index field 'resourceTitleObject' value on '10.17600/14000100', caused by Document with id 10.17600/14000100 not found
```
This is due to either remote record links not present in index eg. DOI or to an empty index and document search returns no document at starts.

It is triggered mainly in https://github.com/geonetwork/core-geonetwork/blob/main/web/src/main/webapp/xslt/common/index-utils.xsl#L141 but the `recordLink` field is currently not used in main UI.

Related to e606996 and 20cc13b
  • Loading branch information
fxprunayre authored and github-actions[bot] committed Oct 25, 2024
1 parent 7dffca2 commit 1480882
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/main/java/org/fao/geonet/util/XslUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -862,7 +862,7 @@ public static String getIndexField(Object appName, Object uuid, Object field, Ob
final Map<String, String> values = searchManager.getFieldsValues(id, fields, language);
return values.get(fieldname);
} catch (Exception e) {
Log.error(Geonet.GEONETWORK, "Failed to get index field '" + fieldname + "' value on '" + id + "', caused by " + e.getMessage());
Log.warning(Geonet.GEONETWORK, "Failed to get index field '" + fieldname + "' value on '" + id + "', caused by " + e.getMessage());
}
return "";
}
Expand Down

0 comments on commit 1480882

Please sign in to comment.