You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "xinyiZzz (via GitHub)" <gi...@apache.org> on 2023/02/21 08:37:00 UTC

[GitHub] [doris] xinyiZzz opened a new pull request, #16987: [improvement](memory) Support GC segment cache, when memory insufficient

xinyiZzz opened a new pull request, #16987:
URL: https://github.com/apache/doris/pull/16987

   # Proposed changes
   
   Issue Number: close #xxx
   
   ## Problem summary
   
   1. fix segment cache memory tracker statistics
   2. support GC
   
   ## Checklist(Required)
   
   * [ ] Does it affect the original behavior
   * [ ] Has unit tests been added
   * [ ] Has document been added or modified
   * [ ] Does it need to update dependencies
   * [ ] Is this PR support rollback (If NO, please explain WHY)
   
   ## Further comments
   
   If this is a relatively large or complex change, kick off the discussion at [dev@doris.apache.org](mailto:dev@doris.apache.org) by explaining why you chose the solution you did and what alternatives you considered, etc...
   
   


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438458358

   clang-tidy review says "All clean, LGTM! :+1:"


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438197610

   clang-tidy review says "All clean, LGTM! :+1:"


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] hello-stephen commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "hello-stephen (via GitHub)" <gi...@apache.org>.
hello-stephen commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438306331

   TeamCity pipeline, clickbench performance test result:
    the sum of best hot time: 33.98 seconds
    stream load tsv:          461 seconds loaded 74807831229 Bytes, about 154 MB/s
    stream load json:         38 seconds loaded 2358488459 Bytes, about 59 MB/s
    stream load orc:          67 seconds loaded 1101869774 Bytes, about 15 MB/s
    stream load parquet:          27 seconds loaded 861443392 Bytes, about 30 MB/s
    https://doris-community-test-1308700295.cos.ap-hongkong.myqcloud.com/tmp/20230221111840_clickbench_pr_101045.html


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113811013


##########
be/src/util/mem_info.cpp:
##########
@@ -97,6 +98,8 @@ void MemInfo::process_cache_gc(int64_t& freed_mem) {
     freed_mem +=
             StoragePageCache::instance()->get_page_cache_mem_consumption(segment_v2::DATA_PAGE);
     StoragePageCache::instance()->prune(segment_v2::DATA_PAGE);
+    // TODO add freed_mem
+    SegmentLoader::instance()->prune();

Review Comment:
   minor gc, the remaining memory is less than 10% of the total memory, so prune outdated segment cache



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1439482188

   run buildall


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438110255

   clang-tidy review says "All clean, LGTM! :+1:"


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438207305

   run buildall


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] zhannngchen commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "zhannngchen (via GitHub)" <gi...@apache.org>.
zhannngchen commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113804330


##########
be/src/util/mem_info.cpp:
##########
@@ -97,6 +98,8 @@ void MemInfo::process_cache_gc(int64_t& freed_mem) {
     freed_mem +=
             StoragePageCache::instance()->get_page_cache_mem_consumption(segment_v2::DATA_PAGE);
     StoragePageCache::instance()->prune(segment_v2::DATA_PAGE);
+    // TODO add freed_mem
+    SegmentLoader::instance()->prune();

Review Comment:
   with the pr: https://github.com/apache/doris/pull/17011, the `prune()` here seems not necessary.



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113738207


##########
be/src/util/mem_info.cpp:
##########
@@ -97,6 +98,8 @@ void MemInfo::process_cache_gc(int64_t& freed_mem) {
     freed_mem +=
             StoragePageCache::instance()->get_page_cache_mem_consumption(segment_v2::DATA_PAGE);
     StoragePageCache::instance()->prune(segment_v2::DATA_PAGE);
+    freed_mem += SegmentLoader::instance()->segment_cache_mem_consumption();
+    SegmentLoader::instance()->prune_all();

Review Comment:
   fixed,
   minor gc only prune outdated segment cache
   full gc prune all



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1439318661

   clang-tidy review says "All clean, LGTM! :+1:"


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113838369


##########
be/src/olap/segment_loader.cpp:
##########
@@ -52,8 +53,14 @@ void SegmentLoader::_insert(const SegmentLoader::CacheKey& key, SegmentLoader::C
         delete cache_value;
     };
 
+    int64_t meta_mem_usage = 0;
+    for (auto segment : value.segments) {
+        meta_mem_usage += segment->meta_mem_usage();
+    }
+
     auto lru_handle = _cache->insert(key.encode(), &value, sizeof(SegmentLoader::CacheValue),
-                                     deleter, CachePriority::NORMAL);
+                                     deleter, CachePriority::NORMAL, meta_mem_usage);
+    << _cache->mem_consumption();

Review Comment:
   warning: expected expression [clang-diagnostic-error]
   ```cpp
       << _cache->mem_consumption();
       ^
   ```
   



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438049197

   run buildall


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438452450

   run buildall


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438101582

   run buildall


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1439316480

   run buildall


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1438436287

   clang-tidy review says "All clean, LGTM! :+1:"


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] zhannngchen commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "zhannngchen (via GitHub)" <gi...@apache.org>.
zhannngchen commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113797968


##########
be/src/olap/segment_loader.cpp:
##########
@@ -52,8 +53,15 @@ void SegmentLoader::_insert(const SegmentLoader::CacheKey& key, SegmentLoader::C
         delete cache_value;
     };
 
+    int64_t meta_mem_usage = 0;
+    for (auto segment : value.segments) {
+        meta_mem_usage += segment->meta_mem_usage();
+    }
+
     auto lru_handle = _cache->insert(key.encode(), &value, sizeof(SegmentLoader::CacheValue),
-                                     deleter, CachePriority::NORMAL);
+                                     deleter, CachePriority::NORMAL, meta_mem_usage);
+    LOG(INFO) << "1111111 " << sizeof(SegmentLoader::CacheValue) << ", " << meta_mem_usage << ", "

Review Comment:
   111111? 



##########
be/src/util/mem_info.cpp:
##########
@@ -97,6 +98,8 @@ void MemInfo::process_cache_gc(int64_t& freed_mem) {
     freed_mem +=
             StoragePageCache::instance()->get_page_cache_mem_consumption(segment_v2::DATA_PAGE);
     StoragePageCache::instance()->prune(segment_v2::DATA_PAGE);
+    // TODO add freed_mem
+    SegmentLoader::instance()->prune();

Review Comment:
   Why do we need to call `prune()` here? 



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113806870


##########
be/src/olap/segment_loader.cpp:
##########
@@ -52,8 +53,15 @@ void SegmentLoader::_insert(const SegmentLoader::CacheKey& key, SegmentLoader::C
         delete cache_value;
     };
 
+    int64_t meta_mem_usage = 0;
+    for (auto segment : value.segments) {
+        meta_mem_usage += segment->meta_mem_usage();
+    }
+
     auto lru_handle = _cache->insert(key.encode(), &value, sizeof(SegmentLoader::CacheValue),
-                                     deleter, CachePriority::NORMAL);
+                                     deleter, CachePriority::NORMAL, meta_mem_usage);
+    LOG(INFO) << "1111111 " << sizeof(SegmentLoader::CacheValue) << ", " << meta_mem_usage << ", "

Review Comment:
   fixed, mistake……



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1112731759


##########
be/src/olap/rowset/segment_v2/segment.h:
##########
@@ -116,6 +116,8 @@ class Segment : public std::enable_shared_from_this<Segment> {
 
     io::FileReaderSPtr file_reader() { return _file_reader; }
 
+    int64_t meta_mem_usage() { return _meta_mem_usage; }

Review Comment:
   warning: method 'meta_mem_usage' can be made const [readability-make-member-function-const]
   
   ```suggestion
       int64_t meta_mem_usage() const { return _meta_mem_usage; }
   ```
   



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113836779


##########
be/src/util/mem_info.cpp:
##########
@@ -97,6 +98,8 @@ void MemInfo::process_cache_gc(int64_t& freed_mem) {
     freed_mem +=
             StoragePageCache::instance()->get_page_cache_mem_consumption(segment_v2::DATA_PAGE);
     StoragePageCache::instance()->prune(segment_v2::DATA_PAGE);
+    // TODO add freed_mem
+    SegmentLoader::instance()->prune();

Review Comment:
   not conflict with periodic gc in #17011



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1439449258

   clang-tidy review says "All clean, LGTM! :+1:"


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] zhannngchen commented on a diff in pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "zhannngchen (via GitHub)" <gi...@apache.org>.
zhannngchen commented on code in PR #16987:
URL: https://github.com/apache/doris/pull/16987#discussion_r1113132461


##########
be/src/util/mem_info.cpp:
##########
@@ -97,6 +98,8 @@ void MemInfo::process_cache_gc(int64_t& freed_mem) {
     freed_mem +=
             StoragePageCache::instance()->get_page_cache_mem_consumption(segment_v2::DATA_PAGE);
     StoragePageCache::instance()->prune(segment_v2::DATA_PAGE);
+    freed_mem += SegmentLoader::instance()->segment_cache_mem_consumption();
+    SegmentLoader::instance()->prune_all();

Review Comment:
   It's too aggressive, we may just need to call `prune_all()` when full gc.
   Segment cache is quite useful on accelerating queries and MoW index lookup.



-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] yiguolei merged pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

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


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] xinyiZzz commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "xinyiZzz (via GitHub)" <gi...@apache.org>.
xinyiZzz commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1439402936

   run arm


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1439452808

   PR approved by at least one committer and no changes requested.


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] github-actions[bot] commented on pull request #16987: [improvement](memory) Support GC segment cache, when memory insufficient

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #16987:
URL: https://github.com/apache/doris/pull/16987#issuecomment-1439452840

   PR approved by anyone and no changes requested.


-- 
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: commits-unsubscribe@doris.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org