Apache Lucene open-source search software
SOLR-13432: Add .toString methods to BitDocSet and SortedIntDocSet so that enabling "showItems" on the filter caches shows some useful information about the values in the cache
Shalin Shekhar Mangarf77c56dbc636
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txtindex 35b5b1154d0..c1be8447e63 100644--- a/solr/CHANGES.txt+++ b/solr/CHANGES.txt@@ -258,6 +258,9 @@ Improvements* SOLR-13394: Switch default GC from CMS to G1 (Ishan Chattopadhyaya, Kesharee Nandan Vishwakarma, Shawn Heisey,Uwe Schindler, Erick Ericsson)+* SOLR-13432: Add .toString methods to BitDocSet and SortedIntDocSet so that enabling "showItems" on the filter caches+ shows some useful information about the values in the cache. (shalin)+Other Changes----------------------diff --git a/solr/core/src/java/org/apache/solr/search/BitDocSet.java b/solr/core/src/java/org/apache/solr/search/BitDocSet.javaindex a3141a75425..af7f3df549d 100644--- a/solr/core/src/java/org/apache/solr/search/BitDocSet.java+++ b/solr/core/src/java/org/apache/solr/search/BitDocSet.java@@ -385,4 +385,12 @@ public class BitDocSet extends DocSetBase {public Collection<Accountable> getChildResources() {return Collections.emptyList();}++ @Override+ public String toString() {+ return "BitDocSet{" ++ "size=" + size() ++ ",ramUsed=" + RamUsageEstimator.humanReadableUnits(ramBytesUsed()) ++ '}';+ }}diff --git a/solr/core/src/java/org/apache/solr/search/SortedIntDocSet.java b/solr/core/src/java/org/apache/solr/search/SortedIntDocSet.javaindex aa96d8cb7bc..522b4c42c8d 100644--- a/solr/core/src/java/org/apache/solr/search/SortedIntDocSet.java+++ b/solr/core/src/java/org/apache/solr/search/SortedIntDocSet.java@@ -804,4 +804,12 @@ public class SortedIntDocSet extends DocSetBase {public Collection<Accountable> getChildResources() {return Collections.emptyList();}++ @Override+ public String toString() {+ return "SortedIntDocSet{" ++ "size=" + size() + "," ++ "ramUsed=" + RamUsageEstimator.humanReadableUnits(ramBytesUsed())++ '}';+ }}