Re: to handle expired documents: collection alias or delete by id query

2017-03-26 Thread Derek Poh
Hi Tom The moving alias design is interesting, will explore it. Regarding themethod of creating the collection on a node for indexing only and adding replicas of it to other nodes for queryinguponcompletion of indexing. Am I right to say this is used in conjunction with collection alias or th

Re: to handle expired documents: collection alias or delete by id query

2017-03-24 Thread Tom Evans
On Thu, Mar 23, 2017 at 6:10 AM, Derek Poh wrote: > Hi > > I have collections of products. I am doing indexing 3-4 times daily. > Every day there are products that expired and I need to remove them from > these collectionsdaily. > > Ican think of 2 ways to do this. > 1. using collection aliasto sw

Re: to handle expired documents: collection alias or delete by id query

2017-03-23 Thread Derek Poh
Erick Generally the products have contracted date but they could be extended and also get expired prematurely. We will need additional processing to cater for these scenarios and update the 'expiry date' fields accordingly. Will go through thedocumentationagainand see if it can fitour use cas

Re: to handle expired documents: collection alias or delete by id query

2017-03-23 Thread Derek Poh
Hi Emir Thank you for pointing outdeleted docwill still existin the indextill it is optimize and itwill skewed statistics. We dosort by score. This new collectionsare partofa new business initiativeandwe do not know as yet what will be their sizelike. Willgo ponder on your inputs. Thank you

Re: to handle expired documents: collection alias or delete by id query

2017-03-23 Thread Erick Erickson
have you considered using TTL (Time To Live)? You have to know at index time when the doc will expire. If you do, Solr will delete the doc for you when its life is over. See: https://lucidworks.com/2014/05/07/document-expiration/ Also the Ref guide: https://cwiki.apache.org/confluence/display/solr

Re: to handle expired documents: collection alias or delete by id query

2017-03-23 Thread Emir Arnautovic
Hi Derek, There are both pros and cons for both approaches: 1. if you are doing full reindexing PRO is that you have clean index all the time and even if something goes wrong, you don't have to switch alias to updated index so your users will not notice issues. CON is that you are doing full

to handle expired documents: collection alias or delete by id query

2017-03-22 Thread Derek Poh
Hi I have collections of products. I am doing indexing 3-4 times daily. Every day there are products that expired and I need to remove them from these collectionsdaily. Ican think of 2 ways to do this. 1. using collection aliasto switch between a main and temp collection. - clear and index the