lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Muir (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LUCENE-2510) migrate solr analysis factories to analyzers module
Date Mon, 07 May 2012 14:12:48 GMT

    [ https://issues.apache.org/jira/browse/LUCENE-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13269636#comment-13269636
] 

Robert Muir commented on LUCENE-2510:
-------------------------------------

{quote}
How would we support Factories loading unrelated classes like they can through ResourceLoader
now? Assume they're on the classpath and use Class.forName?
{quote}

I think there are only a few situations of this? Like your payload example? If PayloadEncoder
really needs to be
pluggable by class then you always also put it under SPI too (PayloadEncoder.forName).

In general if we decide on the SPI approach, I think it would be useful to think of improving
the solr config too,
because the current configuration is so verbose and redundant.
e.g. for backwards compat we could support:

{noformat}
<charFilter class="solr.HtmlStripCharFilterFactory"/>
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<filter class="solr.PorterStemFilterFactory"/>
{noformat}

but going forward this would be cleaner IMO, just use the SPI name directly:

{noformat}
<charFilter name="HtmlStrip"/>
<tokenizer name="Standard"/>
<filter name="LowerCase"/>
<filter name="PorterStem"/>
{noformat}

                
> migrate solr analysis factories to analyzers module
> ---------------------------------------------------
>
>                 Key: LUCENE-2510
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2510
>             Project: Lucene - Java
>          Issue Type: Task
>          Components: modules/analysis
>    Affects Versions: 4.0
>            Reporter: Robert Muir
>             Fix For: 4.0
>
>         Attachments: LUCENE-2510-parent-classes.patch, LUCENE-2510-parent-classes.patch,
LUCENE-2510-parent-classes.patch, LUCENE-2510-resourceloader-bw.patch, LUCENE-2510.patch,
LUCENE-2510.patch, LUCENE-2510.patch
>
>
> In LUCENE-2413 all TokenStreams were consolidated into the analyzers module.
> This is a good step, but I think the next step is to put the Solr factories into the
analyzers module, too.
> This would make analyzers artifacts plugins to both lucene and solr, with benefits such
as:
> * users could use the old analyzers module with solr, too. This is a good step to use
real library versions instead of Version for backwards compat.
> * analyzers modules such as smartcn and icu, that aren't currently available to solr
users due to large file sizes or dependencies, would be simple optional plugins to solr and
easily available to users that want them.
> Rough sketch in this thread: http://www.lucidimagination.com/search/document/3465a0e55ba94d58/solr_and_analyzers_module
> Practically, I havent looked much and don't really have a plan for how this will work
yet, so ideas are very welcome.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Mime
View raw message