You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by "DanielWang2035 (via GitHub)" <gi...@apache.org> on 2025/03/10 06:09:09 UTC
[PR] Load: Fix memory size counting on cases when query engine's memory is not sufficient [iotdb]
DanielWang2035 opened a new pull request, #15049:
URL: https://github.com/apache/iotdb/pull/15049
(no comment)
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Load: Fix memory size counting on cases when query engine's memory is not sufficient [iotdb]
Posted by "SteveYurongSu (via GitHub)" <gi...@apache.org>.
SteveYurongSu merged PR #15049:
URL: https://github.com/apache/iotdb/pull/15049
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Load: Fix memory size counting on cases when query engine's memory is not sufficient [iotdb]
Posted by "SteveYurongSu (via GitHub)" <gi...@apache.org>.
SteveYurongSu commented on code in PR #15049:
URL: https://github.com/apache/iotdb/pull/15049#discussion_r1986755993
##########
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/load/memory/LoadTsFileMemoryManager.java:
##########
@@ -88,17 +88,24 @@ public synchronized void releaseToQuery(long sizeInBytes) {
sizeInBytes,
usedMemorySizeInBytes.get());
}
- usedMemorySizeInBytes.addAndGet(-sizeInBytes);
- QUERY_ENGINE_MEMORY_MANAGER.releaseToFreeMemoryForOperators(sizeInBytes);
+ final long sizeToRelease = Math.min(sizeInBytes, usedMemorySizeInBytes.get());
+ usedMemorySizeInBytes.addAndGet(-sizeToRelease);
+ QUERY_ENGINE_MEMORY_MANAGER.releaseToFreeMemoryForOperators(sizeToRelease);
this.notifyAll();
}
public synchronized LoadTsFileAnalyzeSchemaMemoryBlock allocateAnalyzeSchemaMemoryBlock(
long sizeInBytes) throws LoadRuntimeOutOfMemoryException {
try {
forceAllocateFromQuery(sizeInBytes);
+ LOGGER.info(
+ "Load: Allocated AnalyzeSchemaMemoryBlock from query engine, size: {}", sizeInBytes);
Review Comment:
is debug enabled -> log.debug
--
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: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org