wernerdv commented on code in PR #13554:
URL: https://github.com/apache/ignite/pull/13554#discussion_r4129732603
##########
modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/freelist/AbstractFreeList.java:
##########
@@ -615,7 +616,15 @@ private long allocateDataPage(int part) throws
IgniteCheckedException {
* max), so a fresh {@code allocateDataPage} could no longer grow it.
*/
private boolean regionEffectivelyFull() {
- return pageMem.loadedPages() >= dataRegion.config().getMaxSize() /
pageMem.systemPageSize();
+ long maxPages = dataRegion.config().getMaxSize() /
pageMem.systemPageSize();
+
+ // Each of up to 16 segments loses up to one page to allocation
overhead (lastAllocatedIdxPtr + alignment),
+ // so the theoretical max is never reached in practice. Subtract the
worst-case segment loss to get an
+ // effective limit that reflects real product scenarios.
+ if (maxPages > 16)
Review Comment:
Done
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]