SOLR-536: use ConcurrentHashMap

git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@663686 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Ryan McKinley 2008-06-05 18:03:21 +00:00
parent edf6ed2faf
commit eaaf6236da
1 changed files with 2 additions and 2 deletions

View File

@ -24,6 +24,7 @@ import java.lang.reflect.AccessibleObject;
import java.lang.reflect.Method;
import java.lang.reflect.Array;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;
/**
* A class to map objects to and from solr documents.
@ -32,8 +33,7 @@ import java.util.*;
* @since solr 1.3
*/
public class DocumentObjectBinder {
private final Map<Class, List<DocField>> infocache =
Collections.synchronizedMap( new HashMap<Class, List<DocField>>() );
private final Map<Class, List<DocField>> infocache = new ConcurrentHashMap<Class, List<DocField>>();
public DocumentObjectBinder() {
}