Hi Joel,
Looks great! +1 to push, thanks.
Mike McCandless
http://blog.mikemccandless.com
On Thu, May 14, 2020 at 4:56 PM Joel Bernstein wrote:
> Ok thanks, this makes sense. It's safe to use for the same SortedDocValues
> instance until the method is called again. I think changing the
Ok thanks, this makes sense. It's safe to use for the same SortedDocValues
instance until the method is called again. I think changing the javadoc to
the following will help clear up the confusion:
/** Retrieves the value for the specified ordinal. The returned
* {@link BytesRef} may be re-used
Hi Joel,
You should trust the javadocs.
Looking at our default Codec on master (Lucene84Codec), and at its default
doc values implementation (Lucene80DocValuesProducer), it is clearly
reusing the private "BytesRef term" instance.
If your code is fully consuming this BytesRef before calling any
In the SortedDocValues.lookupOrd documentation it says that a deep
copy is needed for the returned BytesRef. I wanted to verify that this
was actually true. I'm
trying to see a way that this BytesRef could be safely reused by the
API but I don't see one. Is there actually an implementation of