GitHub user laimis opened a pull request:

    https://github.com/apache/lucenenet/pull/46

    Field cache sanitychecker composite reader context fixes

    Cache sanity checker was throwing "value too large" exception when reading 
back the max double stored in the document. The issue is that Convert.ToString 
on double uses 15 precision digits when serializing so the value is rounded up 
making it too large when the value is extracted from the doc. Using double's 
ToString and specifing "R" format makes it use 17 precision digits if needed.
    
    Lucene.Net.Core/Index/CompositeReaderContext was creating a new array from 
"IList children" that was passed to it when the calling code was expecting it 
to store a reference to the passed in array. Lucene version also makes sure 
that unmodifiableList is stored 
(https://github.com/apache/lucene-solr/blob/lucene_solr_4_8_0/lucene/core/src/java/org/apache/lucene/index/CompositeReaderContext.java)
 so added UnmodifiableList implementation.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/laimis/lucenenet 
FieldCacheSanitychecker_CompositeReaderContext_fixes

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/lucenenet/pull/46.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #46
    
----
commit 7970bb64e609e6feb63030fcfcfe2718291706c0
Author: Laimonas Simutis <[email protected]>
Date:   2015-01-10T12:45:54Z

    use appropriate precision digits

commit 08fd1990299bbbb1d4128fc71960f3069fb1556e
Author: Laimonas Simutis <[email protected]>
Date:   2015-01-10T12:46:52Z

    second param is number of items not max range

commit da67eb0638e35a210c032f8ab6bc56702e227d36
Author: Laimonas Simutis <[email protected]>
Date:   2015-01-10T12:48:57Z

    use UnmodifiedList as a reference to children array

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to