0

When reindexing on Sitecore 9.1, a folder with all the images is created ..\App_Data\mediaIndexing. My problem is that it gets very big in size, > 55GB of images in my case. Has anyone encountered this problem because I couldn't find anything about this.

  • interesting! I have never seen mediaIndexing folder :) – Mahendra Shekhawat Sep 24 at 17:45
1

This is done as part of the extraction of the content of media items for the _content field. See for example Sitecore.ContentSearch.Solr.DefaultIndexConfiguration.config where it has the type Sitecore.ContentSearch.ComputedFields.MediaItemContentExtractor,Sitecore.ContentSearch. The file mapping is done in the node at contentSearch/indexConfigurations/defaultSolrIndexConfiguration/mediaIndexing. If you would like to disable this, you could create a patch file to remove this field. Something like:

<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
  <sitecore>
    <contentSearch>
      <indexConfigurations>
        <defaultSolrIndexConfiguration>
          <documentOptions>
            <fields hint="raw:AddComputedIndexField">
              <field type="Sitecore.ContentSearch.ComputedFields.MediaItemContentExtractor,Sitecore.ContentSearch">
                <patch:delete />
              </field>
            </fields>
          </documentOptions>
        </defaultSolrIndexConfiguration>
      </indexConfigurations>
    </contentSearch>
  </sitecore>
</configuration>
  • Only thing I would add is to be a little careful about removing fieldName="_content" because it is often augmented by custom computed indexers for indexing datasources for exmaple (e.g. kamsar.net/index.php/2014/05/indexing-subcontent). It might be safer to target the type attribute in the patch. – jammykam Sep 25 at 3:09
  • Ah, good call, didn't realize people were doing that. Not sure I like the idea of adding multiple entries for _content, but if people are doing it, so be it. – Matthew FitzGerald-Chamberlain Sep 25 at 3:34
  • That field is used internally and already has indexed data added to it, so it is not uncommon to further augment that data: sitecore.stackexchange.com/questions/8609/… – jammykam Sep 25 at 14:30
  • Thank you @MatthewFitzGerald-Chamberlain. Yes, I had to change the fieldName (_content) with type (Sitecore.ContentSearch.ComputedFields.MediaItemContentExtractor,Sitecore.ContentSearch) and it worked. – Ivana Sep 25 at 15:43
  • 1
    @Ivana That's great. If you don't mind, please go ahead and accept this answer if it solved your problem. :) – Matthew FitzGerald-Chamberlain Sep 25 at 16:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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