Skip to content

Commit

Permalink
Query/Filter Facet should support 64bit counter, not 32
Browse files Browse the repository at this point in the history
closes #3419
  • Loading branch information
kimchy committed Jul 31, 2013
1 parent db0a5f0 commit 10011ff
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
Expand Up @@ -40,7 +40,7 @@ public class FilterFacetExecutor extends FacetExecutor {

private final Filter filter;

int count = -1;
long count = -1;

public FilterFacetExecutor(Filter filter) {
this.filter = filter;
Expand Down Expand Up @@ -82,7 +82,7 @@ public void executePost(List<ContextDocIdSet> docSets) throws IOException {

class Collector extends FacetExecutor.Collector {

private int count = 0;
private long count = 0;
private Bits bits;

@Override
Expand Down
Expand Up @@ -83,7 +83,7 @@ public Facet reduce(ReduceContext context) {
if (facets.size() == 1) {
return facets.get(0);
}
int count = 0;
long count = 0;
for (Facet facet : facets) {
count += ((FilterFacet) facet).getCount();
}
Expand Down
Expand Up @@ -81,7 +81,7 @@ public Facet reduce(ReduceContext context) {
if (facets.size() == 1) {
return facets.get(0);
}
int count = 0;
long count = 0;
for (Facet facet : facets) {
count += ((QueryFacet) facet).getCount();
}
Expand Down
Expand Up @@ -43,7 +43,7 @@ public class QueryFacetExecutor extends FacetExecutor {
private final Filter filter;

// default to not initialized
int count = -1;
long count = -1;

public QueryFacetExecutor(Query query) {
this.query = query;
Expand Down Expand Up @@ -91,7 +91,7 @@ public void executePost(List<ContextDocIdSet> docSets) throws IOException {

class Collector extends FacetExecutor.Collector {

private int count = 0;
private long count = 0;
private Bits bits;

@Override
Expand Down

0 comments on commit 10011ff

Please sign in to comment.