mirror of https://github.com/apache/lucene.git
LUCENE-10021: Upgrade HPPC to 0.9.0. Replace usage of ...ScatterMap to ...HashMap (#209)
This commit is contained in:
parent
180cfa241b
commit
caa822ff38
|
@ -297,6 +297,8 @@ Other
|
|||
|
||||
* LUCENE-9391: Upgrade HPPC to 0.8.2. (Haoyu Zhai)
|
||||
|
||||
* LUCENE-10021: Upgrade HPPC to 0.9.0. Replace usage of ...ScatterMap to ...HashMap. (Patrick Zhai)
|
||||
|
||||
* LUCENE-8768: Fix Javadocs build in Java 11. (Namgyu Kim)
|
||||
|
||||
* LUCENE-9092: upgrade randomizedtesting to 2.7.5 (Dawid Weiss)
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
|
||||
package org.apache.lucene.facet;
|
||||
|
||||
import com.carrotsearch.hppc.LongIntScatterMap;
|
||||
import com.carrotsearch.hppc.LongIntHashMap;
|
||||
import com.carrotsearch.hppc.cursors.LongIntCursor;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
|
@ -52,7 +52,7 @@ public class LongValueFacetCounts extends Facets {
|
|||
private final int[] counts = new int[1024];
|
||||
|
||||
/** Used for all values that are >= 1K. */
|
||||
private final LongIntScatterMap hashCounts = new LongIntScatterMap();
|
||||
private final LongIntHashMap hashCounts = new LongIntHashMap();
|
||||
|
||||
/** Field being counted. */
|
||||
private final String field;
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
*/
|
||||
package org.apache.lucene.facet;
|
||||
|
||||
import com.carrotsearch.hppc.IntIntScatterMap;
|
||||
import com.carrotsearch.hppc.IntIntHashMap;
|
||||
import com.carrotsearch.hppc.cursors.IntIntCursor;
|
||||
import java.io.IOException;
|
||||
import java.util.Arrays;
|
||||
|
@ -67,7 +67,7 @@ public class StringValueFacetCounts extends Facets {
|
|||
private final SortedSetDocValues docValues;
|
||||
|
||||
private final int[] denseCounts;
|
||||
private final IntIntScatterMap sparseCounts;
|
||||
private final IntIntHashMap sparseCounts;
|
||||
|
||||
private final int cardinality;
|
||||
private int totalDocCount;
|
||||
|
@ -110,7 +110,7 @@ public class StringValueFacetCounts extends Facets {
|
|||
// If our result set is < 10% of the index, we collect sparsely (use hash map). This
|
||||
// heuristic is borrowed from IntTaxonomyFacetCounts:
|
||||
if (totalHits < totalDocs / 10) {
|
||||
sparseCounts = new IntIntScatterMap();
|
||||
sparseCounts = new IntIntHashMap();
|
||||
denseCounts = null;
|
||||
} else {
|
||||
sparseCounts = null;
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
*/
|
||||
package org.apache.lucene.facet.taxonomy;
|
||||
|
||||
import com.carrotsearch.hppc.IntIntScatterMap;
|
||||
import com.carrotsearch.hppc.IntIntHashMap;
|
||||
import com.carrotsearch.hppc.cursors.IntIntCursor;
|
||||
import java.io.IOException;
|
||||
import java.util.Map;
|
||||
|
@ -34,7 +34,7 @@ public abstract class IntTaxonomyFacets extends TaxonomyFacets {
|
|||
/** Per-ordinal value. */
|
||||
private final int[] values;
|
||||
|
||||
private final IntIntScatterMap sparseValues;
|
||||
private final IntIntHashMap sparseValues;
|
||||
|
||||
/** Sole constructor. */
|
||||
protected IntTaxonomyFacets(
|
||||
|
@ -43,7 +43,7 @@ public abstract class IntTaxonomyFacets extends TaxonomyFacets {
|
|||
super(indexFieldName, taxoReader, config);
|
||||
|
||||
if (useHashTable(fc, taxoReader)) {
|
||||
sparseValues = new IntIntScatterMap();
|
||||
sparseValues = new IntIntHashMap();
|
||||
values = null;
|
||||
} else {
|
||||
sparseValues = null;
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
ccb3ef933ead6b5d766fa571582ddb9b447e48c4
|
|
@ -0,0 +1 @@
|
|||
fcc952fb6d378266b943bef9f15e67a4d45cfa88
|
|
@ -1,5 +1,5 @@
|
|||
# Run ./gradlew --write-locks to regenerate this file
|
||||
com.carrotsearch:hppc:0.8.2 (1 constraints: 0c050536)
|
||||
com.carrotsearch:hppc:0.9.0 (1 constraints: 0b050636)
|
||||
com.carrotsearch.randomizedtesting:randomizedtesting-runner:2.7.6 (1 constraints: 11051036)
|
||||
com.ibm.icu:icu4j:68.2 (1 constraints: e4041f31)
|
||||
commons-codec:commons-codec:1.13 (1 constraints: d904f430)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
com.carrotsearch.randomizedtesting:*=2.7.6
|
||||
com.carrotsearch:hppc=0.8.2
|
||||
com.carrotsearch:hppc=0.9.0
|
||||
com.github.ben-manes.caffeine:caffeine=2.8.4
|
||||
com.google.errorprone:*=2.4.0
|
||||
com.google.guava:guava=25.1-jre
|
||||
|
|
Loading…
Reference in New Issue