mirror of
https://github.com/apache/lucene.git
synced 2025-02-24 11:16:35 +00:00
SOLR-7781: change FacetField BytesRef shallow clone to deep clone
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1690541 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
566859fb52
commit
9152164afb
@ -230,6 +230,10 @@ Bug Fixes
|
||||
* SOLR-7529: CoreAdminHandler Reload throws NPE on null core name instead of a bad
|
||||
request error. (Jellyfrog, Edward Ribeiro via shalin)
|
||||
|
||||
* SOLR-7781: JSON Facet API: Terms facet on string/text fields with sub-facets caused
|
||||
a bug that resulted in filter cache lookup misses as well as the filter cache
|
||||
exceeding it's configured size. (yonik)
|
||||
|
||||
Optimizations
|
||||
----------------------
|
||||
|
||||
|
@ -516,6 +516,7 @@ abstract class FacetFieldProcessorFCBase extends FacetFieldProcessor {
|
||||
}
|
||||
|
||||
|
||||
/** this BytesRef may be shared across calls and should be deep-cloned if necessary */
|
||||
abstract protected BytesRef lookupOrd(int ord) throws IOException;
|
||||
abstract protected void findStartAndEndOrds() throws IOException;
|
||||
abstract protected void collectDocs() throws IOException;
|
||||
@ -663,7 +664,7 @@ abstract class FacetFieldProcessorFCBase extends FacetFieldProcessor {
|
||||
|
||||
bucket.add("val", val);
|
||||
|
||||
TermQuery filter = needFilter ? new TermQuery(new Term(sf.getName(), br.clone())) : null;
|
||||
TermQuery filter = needFilter ? new TermQuery(new Term(sf.getName(), BytesRef.deepCopyOf(br))) : null;
|
||||
fillBucket(bucket, countAcc.getCount(slotNum), slotNum, null, filter);
|
||||
|
||||
bucketList.add(bucket);
|
||||
|
Loading…
x
Reference in New Issue
Block a user