0

Indexupdatestrategy(OnPublishEndAsynchronousStrategy) for SOLR index is not updating the index whereas Full index is working fine. Can you please help me to fix this issue. Details are as below.

I am using Sitecore 7.2(rev. 160123) and SOLR 4.10.1(cloud). I have setup my index update strategy as below.

<onPublishEndAsyncLive type="Sitecore.ContentSearch.Maintenance.Strategies.OnPublishEndAsynchronousStrategy, Sitecore.ContentSearch" >
<param desc="database">liveweb</param>
<CheckForThreshold>true</CheckForThreshold>
</onPublishEndAsyncLive>


<index id="my_site_search_liveweb_index" type="Sitecore.ContentSearch.SolrProvider.SwitchOnRebuildSolrSearchIndex, Sitecore.ContentSearch.SolrProvider" patch:source="zCustomSBDIndexes.config">
<param desc="name">$(id)</param>
<param desc="core">my_site_search_liveweb</param>
<param desc="rebuildcore">my_site_search_liveweb_tmp</param>
<param desc="propertyStore" ref="contentSearch/databasePropertyStore" param1="$(id)"/>
<configuration ref="contentSearch/indexConfigurations/sbdSolrIndexConfiguration"/>
<strategies hint="list:AddStrategy">
<strategy ref="contentSearch/indexUpdateStrategies/onPublishEndAsyncLive"/>
</strategies>
<locations hint="list:AddCrawler">
<crawler type="Sitecore.ContentSearch.SitecoreItemCrawler, Sitecore.ContentSearch">
<Database>liveweb</Database>
<Root>/sitecore/content/Product Repository/Products mysite</Root>
</crawler>
<crawler type="Sitecore.ContentSearch.SitecoreItemCrawler, Sitecore.ContentSearch">
<Database>liveweb</Database>
<Root>/sitecore/content/mysite</Root>
</crawler>
<crawler type="Sitecore.ContentSearch.SitecoreItemCrawler, Sitecore.ContentSearch">
<Database>liveweb</Database>
<Root>/sitecore/content/Shared</Root>
</crawler>
</locations>
</index>
  • When I change a field value in sitecore CMS and publish the item to my Liveweb(Target) database, I am not seeing the updated value in my index(even after some wait time).
  • I could see that after publishing the item, EventQueue is having an entry for PublishEndRemote event in the Liveweb db - Sitecore.Eventing.Remote.PublishEndRemoteEvent, Sitecore.Kernel, Version=7.0.0.0, Culture=neutral, PublicKeyToken=null
  • Core Db's Properties table - EQstamp_<> value looks ok with the Stamp value of the EventQueue entry.
  • In the Crawling log with Debug mode, I could see that my_site_search_liveweb_index is triggering in IncrementalUpdate mode and getting committed.Please see the below logs.

Log:

9920 16:53:37 INFO  [Index=my_site_search_liveweb_index] Initializing SitecoreItemCrawler. DB:liveweb / Root:/sitecore/content/Product Repository/Products mysite 
9920 16:53:37 INFO  [Index=my_site_search_liveweb_index] Initializing SitecoreItemCrawler. DB:liveweb / Root:/sitecore/content/mysite 
9920 16:53:37 INFO  [Index=my_site_search_liveweb_index] Initializing SitecoreItemCrawler. DB:liveweb / Root:/sitecore/content/Shared 
9920 16:53:37 INFO  [Index=my_site_search_liveweb_index] Initializing OnPublishEndAsynchronousStrategy. 
9920 16:53:37 DEBUG [Index=my_site_search_liveweb_index] Created access to temporary rebuild core. [my_site_search_liveweb_tmp] 
12932 16:53:37 DEBUG [Index=my_site_search_liveweb_index] OnPublishEndAsynchronousStrategy executing. 
12932 16:53:38 INFO  [Index=my_site_search_liveweb_index] Updating '2' items from Event Queue. 
12932 16:53:38 DEBUG IndexCustodian. IncrementalUpdate triggered on index my_site_search_liveweb_index. Data=Count=2 <<lots of Resolving/Resolved field boosting logs...>> 
ManagedPoolThread #7 16:53:57 DEBUG [Index=my_site_search_liveweb_index] Committing: Add: 10; Update:0; DeleteUnique: 0; DeleteGroup: 0 
ManagedPoolThread #7 16:53:57 DEBUG [Index=my_site_search_liveweb_index] Committed 
ManagedPoolThread #7 16:53:57 DEBUG IndexDependentHtmlCacheManager triggered. ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'shell'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'login'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'admin'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'service'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'modules_shell'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'modules_website'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'mysite'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'mysiteca'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'website'. ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'scheduler'. 
ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'system'. ManagedPoolThread #7 16:53:57 DEBUG Clearing index dependent cache for site 'publisher'. 
ManagedPoolThread #7 16:53:57 DEBUG IndexDependentHtmlCacheManager done.
  • When I go to the SOLR cloud and query the item, I am not seeing the updated value in the field. But when I initiate and complete a full index, I am seeing the updated field value in the index. Any help is much appreciated.
6
  • Did you have more than 1 replication? Commented Jul 25, 2018 at 19:40
  • We are using zookeeper ensemble with 1Leader, 2follower. My understanding is - when the field update happens , it will be updated in the Leader server's index and zookeeper will replicate the change to 2 follower servers.
    – Karthik
    Commented Jul 25, 2018 at 20:46
  • Can you try to check on the other replication? From the solr cloud graph, you can see on which solr instance it is being hit. Go to that solr and then query the cores to see if changes are found Commented Jul 25, 2018 at 21:20
  • Other replication indexes also does not have the updated value :(
    – Karthik
    Commented Jul 26, 2018 at 19:23
  • Are you sure this strategy exists in Sitecore - onPublishEndAsyncLive? I have never seen this one before and a google search only brings up your SO post. Solrcloud should work without the patch mentioned in the answer by Ahmed as far as I know and I have the same ensemble as you (solrcloud 4.10.3). That patch only helps with switch on rebuild functionality and not much more. OOTB solrcloud should work.Check this link for indexing strategies - doc.sitecore.net/sitecore_experience_platform/…
    – Gabbar
    Commented Aug 1, 2018 at 21:28

1 Answer 1

0

Based on this link on github

Out of the box Solr integration for Sitecore 7.x, 8.0 and 8.1 supports Solr 4.x and does not work with SolrCloud that was introduced in Solr 4.10.x versions and was fully implemented in Solr 5.x.

So you may want to upgrade solr to 5.x version and then use the Sitecore Solr patch in github (The patch was developed with Solr 5.2.1 and tested up to Solr 5.5.1.)

1
  • The issue is because of the SOLR cloud we are using and thanks Ahmed for pointing this out.
    – Karthik
    Commented Aug 3, 2018 at 20:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.