Reputation:
Following the instructions in this SDN document (PDF), I added a custom Lucene index to a Sitecore 6.3 website (or so I thought):
<indexes>
section in web.config
, I added my index definition:<indexes> ... <index id="website" singleInstance="true" type="Sitecore.Data.Indexing.Index, Sitecore.Kernel"> <param desc="name">$(id)</param> <fields hint="raw:AddField"> <field target="created">__created</field> <field target="name">@name</field> <field target="body">body</field> <field target="template" storage="keyword">@tid</field> <field target="id" storage="unindexed">@id</field> </fields> </index> </indexes>
master
database:<database id="master" ...> ... <indexes hint="list:AddIndex"> ... <index path="indexes/index[@id='website']" /> </indexes> </database>
master
database already has HistoryEngine
set up (by default), I did not make any additional configuration changes.I can verify that the system
index is getting populated correctly, as the search application in the Sitecore Desktop is able to find items, and the ~/Data/indexes/master/system
directory is chock full of Lucene index files.
However, although the ~/Data/indexes/master/website
directory was created automatically, there are no index files in it, and attempting to perform a search in my sublayout results in the following System.IO.FileNotFoundException
(path abbreviated for simplicity):
no segments* file found in Sitecore.Data.Indexing.FSDirectory@~/Data/indexes/master/website: files:
What additional changes do I need to make to get Sitecore to recognize the new index?
Upvotes: 1
Views: 2178
Reputation:
After doing more some experimentation/research, I discovered that there was actually no additional configuration necessary.
Following the instructions in this blog post, I simply rebuilt the search index for the master database, and everything started working!
I will have to keep an eye on it, though; I thought the search index would be updated automatically every 5 minutes (based on the value of the Indexing.UpdateInterval
setting).
Upvotes: 1