If you use the suggested solution, it will detect the words at indexing
time.
However, Solr's FilterFactory's lifecycle keeps no track on whether a
file for synonyms, keywords etc. has been changed since Solr's last startup.
Therefore a change within these files is not visible until you reload
your core.

Furthermore keywords for old documents aren't added automatically if you
change your keywords (and reload the core) - you have to write a routine
that finds documents matching the new keywords and reindex those documents.

Example:

Your keywordslist at time t1 contains two words:
keyword
codeword

You are indexing two documents:
doc1: {"content":"I am about a secret codeword."}
doc1: {"content":"Happy keyword and the gang."}

Your filter will mark "codeword" in doc1 and "keyword" in doc2 as words
to keep and remove everything else. Therefore their content for your
keepWordField contains only

doc1: {"indexedContent":"codeword"}
doc2: {"indexedContent":"keyword"}

However, if you add the word "gang" to your keywordlist AND reload your
SolrCore, doc2 will still only contain the term "keyword" until it gets
reindexed again.

Kind regards,
Em

Am 22.02.2012 17:56, schrieb Xavier:
> I'm not sure to understand your solution ?
> 
> When (and how) will be the 'word' detection in the fulltext ? before (by my
> own) or during (with) solr indexation ?
> 
> --
> View this message in context: 
> http://lucene.472066.n3.nabble.com/How-to-merge-an-autofacet-with-a-predefined-facet-tp3763988p3767059.html
> Sent from the Solr - User mailing list archive at Nabble.com.
> 

Reply via email to