lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From uschind...@apache.org
Subject svn commit: r1450276 - in /lucene/dev/branches/branch_4x: ./ lucene/ lucene/analysis/ lucene/analysis/common/src/java/org/apache/lucene/analysis/util/ lucene/core/ lucene/core/src/java/org/apache/lucene/util/ solr/
Date Tue, 26 Feb 2013 16:55:23 GMT
Author: uschindler
Date: Tue Feb 26 16:55:22 2013
New Revision: 1450276

URL: http://svn.apache.org/r1450276
Log:
Merged revision(s) 1450275 from lucene/dev/trunk:
LUCENE-4796, SOLR-4373: Fix concurrency issue in NamedSPILoader and AnalysisSPILoader when
doing concurrent core loads in multicore Solr configs

Modified:
    lucene/dev/branches/branch_4x/   (props changed)
    lucene/dev/branches/branch_4x/lucene/   (props changed)
    lucene/dev/branches/branch_4x/lucene/CHANGES.txt   (contents, props changed)
    lucene/dev/branches/branch_4x/lucene/analysis/   (props changed)
    lucene/dev/branches/branch_4x/lucene/analysis/common/src/java/org/apache/lucene/analysis/util/AnalysisSPILoader.java
    lucene/dev/branches/branch_4x/lucene/core/   (props changed)
    lucene/dev/branches/branch_4x/lucene/core/src/java/org/apache/lucene/util/NamedSPILoader.java
    lucene/dev/branches/branch_4x/solr/   (props changed)
    lucene/dev/branches/branch_4x/solr/CHANGES.txt   (contents, props changed)

Modified: lucene/dev/branches/branch_4x/lucene/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/CHANGES.txt?rev=1450276&r1=1450275&r2=1450276&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/CHANGES.txt (original)
+++ lucene/dev/branches/branch_4x/lucene/CHANGES.txt Tue Feb 26 16:55:22 2013
@@ -252,6 +252,10 @@ Bug Fixes
 * LUCENE-4798: PostingsHighlighter's formatter sometimes didn't highlight 
   matched terms.  (Robert Muir)
 
+* LUCENE-4796, SOLR-4373: Fix concurrency issue in NamedSPILoader and
+  AnalysisSPILoader when doing reload (e.g. from Solr).
+  (Uwe Schindler, Hossman)
+
 Documentation
 
 * LUCENE-4718: Fixed documentation of oal.queryparser.classic.

Modified: lucene/dev/branches/branch_4x/lucene/analysis/common/src/java/org/apache/lucene/analysis/util/AnalysisSPILoader.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/analysis/common/src/java/org/apache/lucene/analysis/util/AnalysisSPILoader.java?rev=1450276&r1=1450275&r2=1450276&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/analysis/common/src/java/org/apache/lucene/analysis/util/AnalysisSPILoader.java
(original)
+++ lucene/dev/branches/branch_4x/lucene/analysis/common/src/java/org/apache/lucene/analysis/util/AnalysisSPILoader.java
Tue Feb 26 16:55:22 2013
@@ -66,9 +66,10 @@ final class AnalysisSPILoader<S extends 
    * <p><em>This method is expensive and should only be called for discovery
    * of new service providers on the given classpath/classloader!</em>
    */
-  public void reload(ClassLoader classloader) {
+  public synchronized void reload(ClassLoader classloader) {
+    final LinkedHashMap<String,Class<? extends S>> services =
+      new LinkedHashMap<String,Class<? extends S>>(this.services);
     final SPIClassIterator<S> loader = SPIClassIterator.get(clazz, classloader);
-    final LinkedHashMap<String,Class<? extends S>> services = new LinkedHashMap<String,Class<?
extends S>>();
     while (loader.hasNext()) {
       final Class<? extends S> service = loader.next();
       final String clazzName = service.getSimpleName();

Modified: lucene/dev/branches/branch_4x/lucene/core/src/java/org/apache/lucene/util/NamedSPILoader.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/lucene/core/src/java/org/apache/lucene/util/NamedSPILoader.java?rev=1450276&r1=1450275&r2=1450276&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/lucene/core/src/java/org/apache/lucene/util/NamedSPILoader.java
(original)
+++ lucene/dev/branches/branch_4x/lucene/core/src/java/org/apache/lucene/util/NamedSPILoader.java
Tue Feb 26 16:55:22 2013
@@ -53,7 +53,7 @@ public final class NamedSPILoader<S exte
    * <p><em>This method is expensive and should only be called for discovery
    * of new service providers on the given classpath/classloader!</em>
    */
-  public void reload(ClassLoader classloader) {
+  public synchronized void reload(ClassLoader classloader) {
     final LinkedHashMap<String,S> services = new LinkedHashMap<String,S>(this.services);
     final SPIClassIterator<S> loader = SPIClassIterator.get(clazz, classloader);
     while (loader.hasNext()) {

Modified: lucene/dev/branches/branch_4x/solr/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_4x/solr/CHANGES.txt?rev=1450276&r1=1450275&r2=1450276&view=diff
==============================================================================
--- lucene/dev/branches/branch_4x/solr/CHANGES.txt (original)
+++ lucene/dev/branches/branch_4x/solr/CHANGES.txt Tue Feb 26 16:55:22 2013
@@ -151,6 +151,10 @@ Bug Fixes
 * SOLR-4352: /browse pagination now supports and preserves sort context
   (Eric Spiegelberg, Erik Hatcher)
 
+* LUCENE-4796, SOLR-4373: Fix concurrency issue in NamedSPILoader and
+  AnalysisSPILoader when doing concurrent core loads in multicore
+  Solr configs.  (Uwe Schindler, Hossman)
+
 Optimizations
 ----------------------
 



Mime
View raw message