You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by "Sasilekha (via GitHub)" <gi...@apache.org> on 2026/07/20 05:30:39 UTC

[PR] Fix PointInSetQuery#ramBytesUsed to include retained bounds arrays [lucene]

Sasilekha opened a new pull request, #16406:
URL: https://github.com/apache/lucene/pull/16406

   Addresses #16405
   
   PointInSetQuery retains two byte[] fields (lowerPoint, upperPoint) allocated in its constructor but its cached ramBytesUsed sums only field & sortedPackedPoints where both arrays are missing
   ramBytesUsed = BASE_RAM_BYTES + RamUsageEstimator.sizeOfObject(field) + RamUsageEstimator.sizeOfObject(sortedPackedPoints)
   
   Every non-empty query built via LongPoint.newSetQuery, IntPoint.newSetQuery, FloatPoint.newSetQuery etc therefore underreports its footprint to LRUQueryCache causing cached entries to stay resident longer than maxRamBytesUsed intends to
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix PointInSetQuery#ramBytesUsed to include retained bounds arrays [lucene]

Posted by "Sasilekha (via GitHub)" <gi...@apache.org>.
Sasilekha commented on PR #16406:
URL: https://github.com/apache/lucene/pull/16406#issuecomment-5068663255

   @mikemccand can you help review this pr please?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix PointInSetQuery#ramBytesUsed to include retained bounds arrays [lucene]

Posted by "romseygeek (via GitHub)" <gi...@apache.org>.
romseygeek merged PR #16406:
URL: https://github.com/apache/lucene/pull/16406


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix PointInSetQuery#ramBytesUsed to include retained bounds arrays [lucene]

Posted by "Sasilekha (via GitHub)" <gi...@apache.org>.
Sasilekha commented on PR #16406:
URL: https://github.com/apache/lucene/pull/16406#issuecomment-5156259772

   Hi @romseygeek — would you have bandwidth to take a look? This is a small memory-accounting fix (adds ~28 bytes/query for the retained lower/upper bounds arrays that were missing from ramBytesUsed) with a byte-exact test and a RamUsageTester cross-check. Follows the same shape as #16046 / #16390. Thanks!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org