SOLR-14525: Test failure

This commit is contained in:
noble 2020-06-02 15:52:49 +10:00
parent e841d7625c
commit 552f1940af
1 changed files with 2 additions and 2 deletions

View File

@ -23,7 +23,7 @@ import java.lang.ref.SoftReference;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Iterator; import java.util.Iterator;
import java.util.List; import java.util.List;
import java.util.concurrent.CopyOnWriteArrayList;
import org.apache.solr.core.PluginInfo; import org.apache.solr.core.PluginInfo;
import org.apache.solr.core.SolrCore; import org.apache.solr.core.SolrCore;
import org.apache.solr.logging.MDCLoggingContext; import org.apache.solr.logging.MDCLoggingContext;
@ -42,7 +42,7 @@ public class PackageListeners {
// this registry only keeps a weak reference because it does not want to // this registry only keeps a weak reference because it does not want to
// cause a memory leak if the listener forgets to unregister itself // cause a memory leak if the listener forgets to unregister itself
private List<Reference<Listener>> listeners = new ArrayList<>(); private List<Reference<Listener>> listeners = new CopyOnWriteArrayList<>();
public synchronized void addListener(Listener listener) { public synchronized void addListener(Listener listener) {
listeners.add(new SoftReference<>(listener)); listeners.add(new SoftReference<>(listener));