lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dawid Weiss (Commented) (JIRA)" <>
Subject [jira] [Commented] (LUCENE-3746) suggest.fst.Sort.BufferSize should not automatically fail just because of freeMemory()
Date Sun, 05 Feb 2012 20:06:37 GMT


Dawid Weiss commented on LUCENE-3746:

Just checked and it seems to be that within a single memory pool the results will be atomic.
Unfortunately that call aggregates all memory pools and (depending on the GC used) this may
result in inconsistencies if the calculation happens to be interwoven with garbage collector
activity. As stated in the sources of G1, for example:

// 4) Now, there is a very subtle issue with all the above. The
// framework will call get_memory_usage() on the three pools
// asynchronously. As a result, each call might get a different value
// for, say, survivor_num which will yield inconsistent values for
// eden_used, survivor_used, and old_gen_used (as survivor_num is used
// in the calculation of all three). This would normally be
// ok. However, it's possible that this might cause the sum of
// eden_used, survivor_used, and old_gen_used to go over the max heap
// size and this seems to sometimes cause JConsole (and maybe other
// clients) to get confused. There's not a really an easy / clean
// solution to this problem, due to the asynchrounous nature of the
// framework. 

Makes sense to me. I wouldn't bother with management interface then and just use the Runtime.*
heuristic you proposed.
> suggest.fst.Sort.BufferSize should not automatically fail just because of freeMemory()
> --------------------------------------------------------------------------------------
>                 Key: LUCENE-3746
>                 URL:
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: modules/spellchecker
>            Reporter: Doron Cohen
>             Fix For: 3.6, 4.0
>         Attachments: LUCENE-3746.patch, LUCENE-3746.patch, LUCENE-3746.patch
> Follow up op dev thread: [FSTCompletionTest failure "At least 0.5MB RAM buffer is needed"

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message