-
Notifications
You must be signed in to change notification settings - Fork 18
Description
It appears that when creating cache entries for the public finding aids multiple entries for a collection and rootcontent id can be created, but only one is used. This is on an Archon instance using Microsoft SQL Server.
You can verify by finding a large collection that doesn't properly load...then compare the speeds of...
query to get public that was causing issues
SELECT Dirty,FindingAidText
FROM webuser.tblCollections_FindingAidCache
WHERE CollectionID = <collection_id> AND TemplateSet = <template_name> AND ReadPermissions = 0 AND RootContentID = 0
query to get staff view that loads fine
SELECT Dirty,FindingAidText
FROM webuser.tblCollections_FindingAidCache
WHERE CollectionID = <collection_id> AND TemplateSet = <template_name> AND ReadPermissions = 1 AND RootContentID = 0
First query was returning something like 19 results and taking the first one.
There's a soon-to-be coming pull request that fixes the symptom of this issue by doing a 'TOP 1' w/ an ordering by id descending, but there's an underlying issue that's causing more data than necessary to be stored.
Guessing the issues is with the write part of the findingaidcache.php file.
Discovered with troubleshooting w/ @leonelramirez and @graykr.