Skip to content

Instantly share code, notes, and snippets.

@RyanABailey
Created October 30, 2014 03:24
Show Gist options
  • Select an option

  • Save RyanABailey/3616b6973e882f60e91e to your computer and use it in GitHub Desktop.

Select an option

Save RyanABailey/3616b6973e882f60e91e to your computer and use it in GitHub Desktop.
Sitecore search config
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
<sitecore>
<contentSearch>
<configuration type="Sitecore.ContentSearch.ContentSearchConfiguration, Sitecore.ContentSearch">
<indexes hint="list:AddIndex">
<!-- Change this to Sitecore.ContentSearch.LuceneProvider.SwitchOnRebuildLuceneIndex, Sitecore.ContentSearch.LuceneProvider if you would like indexes to be
built in a temporary directory i.e. while rebuilding is happening, your old indexes work like normal until the rebuild is finished. -->
<index id="content_index" type="Sitecore.ContentSearch.LuceneProvider.LuceneIndex, Sitecore.ContentSearch.LuceneProvider">
<param desc="name">$(id)</param>
<param desc="folder">$(id)</param>
<!-- This initializes index property store. Id has to be set to the index id -->
<param desc="propertyStore" ref="contentSearch/indexConfigurations/databasePropertyStore" param1="$(id)" />
<configuration ref="contentSearch/indexConfigurations/defaultLuceneIndexConfiguration">
<include hint="list:IncludeTemplate">
<template>{5BC5632C-7F22-4A67-9C0D-2873E2F46154}</template>
<template>{C5A5C4B7-5D9F-4117-80AF-D5B2CAED709D}</template>
</include>
<IndexAllFields>true</IndexAllFields>
</configuration>
<strategies hint="list:AddStrategy">
<!-- NOTE: order of these is controls the execution order -->
<strategy ref="contentSearch/indexConfigurations/indexUpdateStrategies/onPublishEndAsync" />
</strategies>
<locations hint="list:AddCrawler">
<crawler type="Sitecore.ContentSearch.SitecoreItemCrawler, Sitecore.ContentSearch">
<Database>web</Database>
<Root>/sitecore/content</Root>
</crawler>
</locations>
</index>
</indexes>
</configuration>
</contentSearch>
</sitecore>
</configuration>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment