You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by "J.J. Larrea (JIRA)" <ji...@apache.org> on 2006/12/05 09:09:21 UTC

[jira] Commented: (SOLR-73) schema.xml and solrconfig.xml use CNET-internal class names

    [ http://issues.apache.org/jira/browse/SOLR-73?page=comments#action_12455539 ] 
            
J.J. Larrea commented on SOLR-73:
---------------------------------

As a user who is both modifying schema.xml and adding custom classes, I'm with Yonik and Hoss on this one -- the class path aliases make life simpler rather than more difficult.  However i also think they can be improved.

I strongly support Hoss' suggestion to make the mappings explicit rather than implicit:

> Would people feel better if we had some sort of '<packageAlias alias="solr">org.apache.solr.analysis</packageAlias>' 
> type directives in both files so that it was less magic and more explicit?

Explicit directives make the xml config files internally self-documenting, and allow for class repositories other than org.apache.solr.analysis;  I'd suggest the element name be 'package' rather than 'packageAlias' so that other attributes could be applied to the package, e.g. custom classloader, base URL for remote loading, etc.

Another change that might be considered would be replacing the dot notation for aliases with a namespace-like notation in order to remove any ambiguity over which class is actually being loaded, especially when there is a multi-level path from the aliased root. Thus:

<package alias="solr">org.apache.solr</package>
<package alias="analyzers">org.apache.solr.analysis</package>

would resolve either "solr:analysis.SynonymFilter" or "analyzers:SynonymFilter" to  org.apache.solr.analysis.SynonymFilter, and of course  "solr:search.LRUCache" to org.apache.solr.search.LRUCache

Do the objectors to solr.* aliases think that would resolve the problematic aspects of aliasing, while still benefitting users by simplifying config files?

> schema.xml and solrconfig.xml use CNET-internal class names
> -----------------------------------------------------------
>
>                 Key: SOLR-73
>                 URL: http://issues.apache.org/jira/browse/SOLR-73
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>            Reporter: Walter Underwood
>
> The configuration files in the example directory still use the old CNET-internal class names, like solr.LRUCache instead of org.apache.solr.search.LRUCache.  This is confusing to new users and should be fixed before the first release.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira