Much depends on how often the index is updated. If your index only changes, say, once a day then it's probably a good idea. If you're constantly updating your index, then I'd recommend that you do _not_ optimize.
Optimizing will create one large segment. That segment will be unlikely to be merged since it is so large relative to other segments for quite a while, resulting in significant wasted space. So if you're regularly indexing documents that _replace_ existing documents, this will skew your index. Bottom line: If you have a relatively static index the you can build and then use for an extended time (as in 12 hours plus) it can be worth the time to optimize. Otherwise I wouldn't bother. Best, Erick On Sun, Dec 20, 2015 at 7:57 PM, Zheng Lin Edwin Yeo <edwinye...@gmail.com> wrote: > Hi, > > I would like to find out, will it be good to do write a script to do an > auto-opitmization of the indexes at a certain time every day? Is there any > advantage to do so? > > I found that optimization can reduce the index size by quite a > signification amount, and allow the searching of the index to run faster. > But will there be advantage if we do the optimization every day? > > I'm using Solr 5.3.0 > > Regards, > Edwin