On Jan 2, 2009, at 10:25 AM, Alexander Ramos Jardim wrote:

Grant,

I am following your idea to write a new TokenFilter.

As long as I looked in SynonymTokenFilter and Factory code, it is the
Factory the reponsible for loading the new

Just let me make some stupid questions:

1. I will have to write a custom TokenFilter and TokenFilterFactory, right?

Yes.


2. SynonymTokenFilterFactory does the "synonyms.txt" parse and creates the SynonymTokenFilter instance. If I want the SynonymTokenFilter to reload synonyms.txt file from time to time, I will need to put the file load and
parsing strategies inside my new TokenFilter, right?

I think it can go in the SynonymFilterFactory.




2008/12/30 Grant Ingersoll <gsing...@apache.org>

I'd probably write a new TokenFilter that was aware of the reload policy (in a generic way) such that I didn't have to go through a whole core reload
every time.  Are you just using them during query time or also during
indexing?

-Grant


On Dec 30, 2008, at 8:12 AM, Alexander Ramos Jardim wrote:

Hello guys,

As the title suggests I must update my synonyms.txt file frequently. What
is
the best approach? Should I send a commit after the file is updated? Does
Solr need to be restarted after the file changes?

--
Alexander Ramos Jardim


--------------------------
Grant Ingersoll

Lucene Helpful Hints:
http://wiki.apache.org/lucene-java/BasicsOfPerformance
http://wiki.apache.org/lucene-java/LuceneFAQ













--
Alexander Ramos Jardim

--------------------------
Grant Ingersoll

Lucene Helpful Hints:
http://wiki.apache.org/lucene-java/BasicsOfPerformance
http://wiki.apache.org/lucene-java/LuceneFAQ










Reply via email to