You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by to...@apache.org on 2019/08/04 14:53:41 UTC

[lucene-solr] branch master updated: LUCENE-8778: Add a migration note to MIGRATE.txt

This is an automated email from the ASF dual-hosted git repository.

tomoko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git


The following commit(s) were added to refs/heads/master by this push:
     new 09993c6  LUCENE-8778: Add a migration note to MIGRATE.txt
09993c6 is described below

commit 09993c6cf0aea840a3f8d73b7596e94aa5569a54
Author: Tomoko Uchida <to...@apache.org>
AuthorDate: Sun Aug 4 23:52:45 2019 +0900

    LUCENE-8778: Add a migration note to MIGRATE.txt
---
 lucene/MIGRATE.txt | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/lucene/MIGRATE.txt b/lucene/MIGRATE.txt
index 7cb7dd9..a063249 100644
--- a/lucene/MIGRATE.txt
+++ b/lucene/MIGRATE.txt
@@ -1,5 +1,20 @@
 # Apache Lucene Migration Guide
 
+## Analysis factories now have customizable symbolic names (LUCENE-8778) ##
+
+The SPI names for concrete subclasses of TokenizerFactory, TokenFilterFactory, and CharfilterFactory are no longer
+derived from their class name. Instead, each factory must have a static "NAME" field like this:
+
+  /** o.a.l.a.standard.StandardTokenizerFactory's SPI name */
+  public static final String NAME = "standard";
+
+A factory can be resolved/instantiated with its NAME by using methods such as TokenizerFactory#lookupClass(String)
+or TokenizerFactory#forName(String, Map<String,String>).
+
+If there are any user-defined factory classes that don't have proper NAME field, an exception will be thrown
+when (re)loading factories. e.g., when calling TokenizerFactory#reloadTokenizers(ClassLoader).
+
+
 ## TermsEnum is now fully abstract (LUCENE-8292) ##
 
 TermsEnum has been changed to be fully abstract, so non-abstract subclass must implement all it's methods.