Bug #10022
AIP re-ingest causing incorrect file count in Archival Storage
Status: | Verified | Start date: | 06/14/2016 | |
---|---|---|---|---|
Priority: | Medium | Due date: | ||
Assignee: | Sarah Romkey | % Done: | 0% | |
Category: | AIP Management | |||
Target version: | Release 1.5.1 | |||
Google Code Legacy ID: | Pull Request: | |||
Sponsored: | No | Requires documentation: |
Description
To reproduce:
- reingest an AIP (first take note of the number of files in the AIP- click on Search Archival Storage to show the file count column)
- After re-storing the AIP, the file count will be twice the original file count
For example, if your AIP has 9 files, after re-ingest the file count will show 18 files.
This may be due to an error in the elasticsearch index.
History
#1 Updated by Holly Becker almost 6 years ago
- Status changed from New to Feedback
- Assignee set to Sarah Romkey
This is an error in Elasticsearch indexing - when we reingest, we don't delete the information for the previous files. This is fixed in the full reingest feature which is scheduled for 1.6, but can be back-ported to 1.5.1 if we decide to do a point release.
diff --git a/src/MCPClient/lib/clientScripts/indexAIP.py b/src/MCPClient/lib/clientScripts/indexAIP.py index aff798a..8b0eb65 100755 --- a/src/MCPClient/lib/clientScripts/indexAIP.py +++ b/src/MCPClient/lib/clientScripts/indexAIP.py @@ -73,8 +73,9 @@ def index_aip(): print('Indexing AIP info') # Delete ES index before creating new one if reingesting if 'REIN' in sip_type: + print('Deleting outdated entry for AIP and AIP files with UUID', sip_uuid, 'from archival storage') elasticSearchFunctions.delete_aip(client, sip_uuid) - print('Deleted outdated entry for AIP with UUID', sip_uuid, ' from archival storage') + elasticSearchFunctions.delete_aip_files(client, sip_uuid) # Index AIP elasticSearchFunctions.index_aip(
#2 Updated by Holly Becker almost 6 years ago
- Status changed from Feedback to Code Review
- Assignee changed from Sarah Romkey to Nick Wilkinson
- AM branch dev/issue-10022-reingest-file-count
- AM PR https://github.com/artefactual/archivematica/pull/473
#3 Updated by Nick Wilkinson almost 6 years ago
- Assignee changed from Nick Wilkinson to Jesús García Crespo
Hi Jesús, assigning to you for CR.
#4 Updated by Jesús García Crespo almost 6 years ago
- Status changed from Code Review to In progress
- Assignee changed from Jesús García Crespo to Holly Becker
LGTM
#5 Updated by Holly Becker almost 6 years ago
- Status changed from In progress to QA/Review
- Assignee changed from Holly Becker to Sarah Romkey
Merged into stable/1.5.x
#6 Updated by Sarah Romkey almost 6 years ago
- Status changed from QA/Review to Verified
Awesome! I re-ingested a test AIP twice and the file count is correct.