mirror of https://github.com/apache/lucene.git
SOLR-9179: NPE in IndexSchema using IBM JDK
This commit is contained in:
parent
30db9e72ba
commit
750bb367d2
|
@ -133,6 +133,8 @@ Bug Fixes
|
||||||
* SOLR-9334: CloudSolrClient.collectionStateCache is unbounded (noble)
|
* SOLR-9334: CloudSolrClient.collectionStateCache is unbounded (noble)
|
||||||
|
|
||||||
|
|
||||||
|
* SOLR-9179: NPE in IndexSchema using IBM JDK (noble, Colvin Cowie)
|
||||||
|
|
||||||
Optimizations
|
Optimizations
|
||||||
----------------------
|
----------------------
|
||||||
|
|
||||||
|
|
|
@ -185,7 +185,7 @@ public class SchemaHandler extends RequestHandlerBase implements SolrCoreAware,
|
||||||
if (parts.get(0).isEmpty()) parts.remove(0);
|
if (parts.get(0).isEmpty()) parts.remove(0);
|
||||||
if (parts.size() > 1 && level2.containsKey(parts.get(1))) {
|
if (parts.size() > 1 && level2.containsKey(parts.get(1))) {
|
||||||
String realName = parts.get(1);
|
String realName = parts.get(1);
|
||||||
String fieldName = IndexSchema.SchemaProps.nameMapping.get(realName);
|
String fieldName = IndexSchema.nameMapping.get(realName);
|
||||||
|
|
||||||
String pathParam = level2.get(realName);
|
String pathParam = level2.get(realName);
|
||||||
if (parts.size() > 2) {
|
if (parts.size() > 2) {
|
||||||
|
|
|
@ -1500,10 +1500,12 @@ public class IndexSchema {
|
||||||
(v1, v2) -> v2,
|
(v1, v2) -> v2,
|
||||||
LinkedHashMap::new));
|
LinkedHashMap::new));
|
||||||
}
|
}
|
||||||
public static Map<String,String> nameMapping = Collections.unmodifiableMap(Stream.of(Handler.values())
|
|
||||||
.collect(Collectors.toMap(Handler::getNameLower , Handler::getRealName)));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static Map<String,String> nameMapping = Collections.unmodifiableMap(Stream.of(SchemaProps.Handler.values())
|
||||||
|
.collect(Collectors.toMap(SchemaProps.Handler::getNameLower , SchemaProps.Handler::getRealName)));
|
||||||
|
|
||||||
|
|
||||||
public Map<String, Object> getNamedPropertyValues(String name, SolrParams params) {
|
public Map<String, Object> getNamedPropertyValues(String name, SolrParams params) {
|
||||||
return new SchemaProps(name, params, this).toMap();
|
return new SchemaProps(name, params, this).toMap();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue