title: Magento index and cache. Do I need both?
body: <p>I am developig an import module which update product data. To speed up the process, I put index to manual mode.</p>
  
  <pre><code>$processes = Mage::getSingleton('index/indexer')-&gt;getProcessesCollection();
  $processes-&gt;walk('setMode', array(Mage_Index_Model_Process::MODE_MANUAL));
  $processes-&gt;walk('save');
  </code></pre>
  
  <p>and after the import is finished, I reindex data and put index mode back to auto</p>
  
  <pre><code>$processes = Mage::getSingleton('index/indexer')-&gt;getProcessesCollection();
  $processes-&gt;walk('reindexAll');
  $processes-&gt;walk('setMode', array(Mage_Index_Model_Process::MODE_REAL_TIME));
  $processes-&gt;walk('save');
  </code></pre>
  
  <p>But I am not sure if I also need to clear cache. So my question is how index and cache are related. For example if I clear cache, does it also reindex all data? And on the other site, if I reindex all data, does it clear cache? Or do I need to trigger everytime both processes if I have index mode set to manual? I am not quite sure about this, I hope anybody could confirm it for sure.</p>
  
  <p>Thank you</p>