You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Hoss Man (JIRA)" <ji...@apache.org> on 2015/11/05 00:57:27 UTC
[jira] [Updated] (SOLR-8239) Deprecate/rename
DefaultSimilarityFactory to ClassicSimilarityFactory and remove
DefaultSimilarityFactory in trunk
[ https://issues.apache.org/jira/browse/SOLR-8239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hoss Man updated SOLR-8239:
---------------------------
Attachment: SOLR-8239.patch
Before applying this patch, run the following svn commands...
{code}
svn cp solr/core/src/java/org/apache/solr/search/similarities/DefaultSimilarityFactory.java solr/core/src/java/org/apache/solr/search/similarities/ClassicSimilarityFactory.java
svn mv solr/core/src/test/org/apache/solr/search/similarities/TestDefaultSimilarityFactory.java solr/core/src/test/org/apache/solr/search/similarities/TestClassicSimilarityFactory.java
{code}
Changes included in patch...
* clone DefaultSimilarityFactory to ClassicSimilarityFactory
* prune DefaultSimilarityFactory down to a trivial subclass of ClassicSimilarityFactory
** class is marked deprecated with link to ClassicSimilarityFactory
** init metod logs a warning about deprecation / new name if used
** class can be removed from trunk after backporting
* Change IndexSchema to use ClassicSimilarityFactory by default instead of DefaultSimilarityFactory
* Change SweetSpotSimilarityFactory to subclass ClassicSimilarityFactory
* update jdocs for SchemaSimilarityFactory & TestNonDefinedSimilarityFactory to refer to ClassicSimilarity/Factory
* update TestSchemaSimilarityResource & (solrj's) SchemaTest to expect ClassicSimilarityFactory as default
* remove gratuitious refrences to DefaultSimilarity / DefaultSimilarityFactory from various test schema files
* rename TestDefaultSimilarityFactory to TestClassicSimilarityFactory
** update javadocs to make it clear this is actually testing _explicit_ uses of the factory on a per-fieldtype basis via SchemaSimilarityFactory
** update test to verify explicit configurations of both ClassicSimilarityFactory & DefaultSimilarityFactory
*** DefaultSimilarityFactory assertions can be removed from trunk after backporting
** refactor existing assertions to legeral two-arg getSimilarity method in superclass
** additions to schema-tfidf.xml as needed for new assertions
*** did some re-org of schema-tfidf.xml for readability
> Deprecate/rename DefaultSimilarityFactory to ClassicSimilarityFactory and remove DefaultSimilarityFactory in trunk
> ------------------------------------------------------------------------------------------------------------------
>
> Key: SOLR-8239
> URL: https://issues.apache.org/jira/browse/SOLR-8239
> Project: Solr
> Issue Type: Sub-task
> Reporter: Hoss Man
> Assignee: Hoss Man
> Fix For: Trunk
>
> Attachments: SOLR-8239.patch
>
>
> As outlined in parent issue...
> * clone DefaultSimilarityFactory -> ClassicSimilarityFactory
> * prune DefaultSimilarityFactory down to a trivial subclass of ClassicSimilarityFactory
> ** make it log a warning on init
> * change default behavior of IndexSchema to use ClassicSimilarityFactory directly
> * mark DefaultSimilarityFactory as deprecated in 5.x, remove from trunk/6.0
> This should put us in a better position moving forward of having the facotry names directly map to the underlying implementation, leaving less ambiguity when an explicit factory is specified in the schema.xml (either as the main similarity, or as a per field similarity)
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org