Details
-
Type: Sub-task
-
Status: Done/Fixed
-
Priority: Major
-
Resolution: Fixed/Completed
-
Affects Version/s: 4.4.0
-
Fix Version/s: 4.4.0
-
Component/s: CiviCRM Search
-
Labels:None
Description
1. Right now the prev/next cache stores the ENTIRE result set. for all searches. For searches with a lot of contacts, this is a large insert. We should only keep this to a small window (1000?) contacts. However this also means we dynamically extend this range when we hit the boundary
2. Today when we click on prev/next, we redo 3 searches: count, get contact ids, get contact results
If we store more information, i.e. the count, and the queries in the cache table, we can reduce the number of queries significantly. Thus on a prev/next if the range is already present in prev next table, we can just use the results query to get all details. If we are outside the range, we can extend the range via the contact id query and then use the results query. So overall we reduce the number of queries by some margin
Attachments
Issue Links
- blocks
-
CRM-13132 Gets tests passing
- Done/Fixed