diff --git a/pom.xml b/pom.xml
index dda1a5f2018..2ad1ed5bc1d 100644
--- a/pom.xml
+++ b/pom.xml
@@ -172,7 +172,7 @@
com.carrotsearch
hppc
- 0.5.2
+ 0.5.3
diff --git a/src/main/java/org/elasticsearch/common/collect/ImmutableOpenMap.java b/src/main/java/org/elasticsearch/common/collect/ImmutableOpenMap.java
index 5686ebe7071..6f4dc9efe1e 100644
--- a/src/main/java/org/elasticsearch/common/collect/ImmutableOpenMap.java
+++ b/src/main/java/org/elasticsearch/common/collect/ImmutableOpenMap.java
@@ -190,6 +190,11 @@ public final class ImmutableOpenMap implements Iterable container) {
return map.putAll(container);
diff --git a/src/main/java/org/elasticsearch/index/cache/id/simple/SimpleIdReaderTypeCache.java b/src/main/java/org/elasticsearch/index/cache/id/simple/SimpleIdReaderTypeCache.java
index 8736a3bdacd..6c94e052d28 100644
--- a/src/main/java/org/elasticsearch/index/cache/id/simple/SimpleIdReaderTypeCache.java
+++ b/src/main/java/org/elasticsearch/index/cache/id/simple/SimpleIdReaderTypeCache.java
@@ -59,13 +59,7 @@ public class SimpleIdReaderTypeCache implements IdReaderTypeCache {
}
public int docById(HashedBytesArray uid) {
- if (idToDoc.containsKey(uid)) {
- // We can't use #lget() here since the idToDoc map shared across threads, so we really need a second lookup...
- // BTW: This method is only used via TopChildrenQuery
- return idToDoc.get(uid);
- } else {
- return -1;
- }
+ return idToDoc.getOrDefault(uid, -1);
}
public HashedBytesArray idByDoc(int docId) {