lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cristian Lorenzetto <cristian.lorenze...@gmail.com>
Subject Re: help for a migration error to 6.1 version
Date Thu, 18 Aug 2016 18:09:34 GMT
using TYPE.setDocValuesType(DocValuesType.SORTED);
 it works.

I didnt undestand the reasons. Maybe for for fast grouping is necessary
maybe to sorting , so algo can find distinct groups

2016-08-18 17:40 GMT+02:00 Cristian Lorenzetto <
cristian.lorenzetto@gmail.com>:

> in my old code
>
> i created public class BinDocValuesField extends Field {
>
> /**
> * Type for numeric DocValues.
> */
> public static final FieldType TYPE = new FieldType();
>
> static {
>
> TYPE.setTokenized(false);
> TYPE.setOmitNorms(true);
> TYPE.setIndexOptions(IndexOptions.DOCS);
> TYPE.setStored(true);
>
> TYPE.setDocValuesType(DocValuesType.BINARY);
> TYPE.freeze();
> }
>
> public BinDocValuesField(String name, byte[] value) {
> super(name, TYPE);
> fieldsData = new BytesRef(value);
> }
>
> }
>
> and in test code i created 4 documents adding BinDocValuesField fields
> where 2 docs has same binary and other 2 the same binary.
>
> executing TopGroups<?> tg = search.search(searcher, query, groupIndex,
>  LIMIT );
>
> now i have 4 groups instead of 2 groups.
> tg.totalGroupCount is correctly 2.
>
> any idea what can be changed?
>
>
>
>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message