On 11/4/22 09:01, Doss wrote:
An alias (memberdetailsindex_alias) was created to get details from both
memberdetailsindex, memberdetailsindex-ram
(/admin/collections?action=CREATEALIAS&name=memberdetailsindex&collections=memberdetailsindex,memberdetailsindex-ram)


Our assumption is, SOLR will get the recently updated records ie., from ram
based index (if a record exists in both ram & disk), but for some request
it gets the old records from memberdetailsindex

The idea I was going to put forward was to list the ram collection first.

But I found when I mocked this up on my own install (the other collection only has one document, but isn't ram-based) and then executed a query for that document multiple times, sometimes it would return the doc in the original collection and sometimes it would return the doc in the new 1-document collection.

I believe that when you have a document with the same value in the uniqueKey field in more than one piece of a distributed index, which document you get has always been undefined.

I think the only real solution available will be to have your application code query the ram index first, and if it doesn't find what it is looking for, query the main index.  Or if you're not querying for a single document you could query both indexes and then merge the results together with the ram collection results overwriting matching documents from the main collection results.

Thanks,
Shawn

Reply via email to