Skip to content

Admin Metadata panel, correct Last Indexed Date value #3586

@wickr

Description

@wickr

Descriptive summary

The Last Indexed Date in the Admin Metadata panel is actually the Date Modified value. Just updating the index of a work does not update this value.

I thought we had a last indexed timestamp in each solr doc, but we do not. For Solr to include it, it needs to be added to the schema. However, Solr's version value in each solr doc is a form of a timestamp that is convertible to a useful date. While not really designed to be a user-facing date, since this is just for the Admin Metadata panel I think it's ok. "The version field is an internal field that is used by the partial update procedure, the update log process, and by SolrCloud."
https://stackoverflow.com/questions/15527380/solr-4-2-what-is-version-field?rq=3

_version_ is time since epoch in milliseconds, multipled by 2^20.

irb(main):027:0> sd['_version_']
=> 1859884193876541440
irb(main):028:0> time_object = Time.at(sd['_version_'] / 1048576 / 1000)
=> 2026-03-17 05:03:07 +0000

Expected behavior

Last Indexed Date should be the actual date the solr doc was updated.

Related work

#3453

Accessibility Concerns

Add any information here to indicate any known or suspected accessibility issues for this ticket

Metadata

Metadata

Assignees

Labels

Content OpsIssues related to import, export, bulkrax, and content processing.MetadataIssues related to metadata configuration, application, and representationPriority - MediumIssues that should be prioritized ahead of low but not immediately critical - bulk of work cycles

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions