lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Moen (Commented) (JIRA)" <>
Subject [jira] [Commented] (SOLR-2909) Add support for ResourceLoaderAware tokenizerFactories in synonym filter factories
Date Mon, 20 Feb 2012 07:58:32 GMT


Christian Moen commented on SOLR-2909:

Ohtani-san, good catch.  Sekiguchi-san, this sounds like a good idea to me.

My understanding is that the problem also occurs when using {{SynonymFilterFactory}} and that
the above will address this case as well since the actual synonym handling is being done by
{{SlowSynonymFilterFactory}} or {{FSTSynonymFilterFactory}} through delegation (based on version).
 Is this correct?  Thanks.
> Add support for ResourceLoaderAware tokenizerFactories in synonym filter factories
> ----------------------------------------------------------------------------------
>                 Key: SOLR-2909
>                 URL:
>             Project: Solr
>          Issue Type: Improvement
>          Components: Schema and Analysis
>    Affects Versions: 3.4, 4.0
>            Reporter: Tom Klonikowski
>            Assignee: Koji Sekiguchi
>            Priority: Minor
> The optional custom tokenizerFactory in SlowSynonymFilterFactory and FSTSynonymFilterFactory
might require the ResourceLoader information. Thus inform(ResourceLoader) should be called
if the specified tokenizerFactory is an instance of ResourceLoaderAware.
> {noformat}
> private static TokenizerFactory loadTokenizerFactory(ResourceLoader loader, String cname,
Map<String, String> args) {
>   TokenizerFactory tokFactory = (TokenizerFactory) loader.newInstance(cname);
>   tokFactory.init(args);
>   if (tokFactory instanceof ResourceLoaderAware) {
>     ((ResourceLoaderAware) tokFactory).inform(loader);
>   }
>   return tokFactory;
> }
> {noformat}

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message