I have a bunch of custom indexes and I need to finetune only 1 of them, not affecting the others. Let's say, I want to change ContentSearch.Update.BatchSize
, is there a way to apply this setting for 1 particular index?
1 Answer
No, that's not possible out of the box.
SolrContextFactory
class, which is responsible for creating IProviderUpdateContect
implementation object, checks if batch mode is enabled for indexing, by checking
`Settings.GetBoolSetting("ContentSearch.Update.BatchModeEnabled")`
If it's not enabled, it creates an object of SolrUpdateContext
.
And if it's enabled, it creates an object of SolrBatchUpdateContext
class with batch size read from configuration - ContentSearch.Update.BatchSize
.
There is no place there for getting batch size for a single index, unless you create a new implementation of AbstractContextFactory
and override GetUpdateContext
method to return index-specific batch size.