Skip to content

Commit 560d95b

Browse files
wybDanRoscigno
authored andcommitted
[Enhancement] Add log for update compaction suspension (StarRocks#70538)
Signed-off-by: wyb <wybb86@gmail.com>
1 parent 069337b commit 560d95b

1 file changed

Lines changed: 20 additions & 0 deletions

File tree

be/src/storage/olap_server.cpp

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -390,6 +390,20 @@ void* StorageEngine::_update_compaction_thread_callback(void* arg, DataDir* data
390390
continue;
391391
}
392392

393+
if (!status.ok()) {
394+
if (!status.is_not_found()) {
395+
LOG_EVERY_N(INFO, 10) << "Update compaction suspended because of status: " << status
396+
<< ", data_dir: " << data_dir->path();
397+
}
398+
} else {
399+
LOG_EVERY_N(INFO, 10) << "Update compaction suspended because memory limit exceeded. "
400+
<< "Compaction mem tracker limit exceeded: "
401+
<< _options.compaction_mem_tracker->any_limit_exceeded()
402+
<< ", Update mem tracker limit exceeded: "
403+
<< _options.update_mem_tracker->any_limit_exceeded()
404+
<< ", data_dir: " << data_dir->path();
405+
}
406+
393407
int32_t interval = config::update_compaction_check_interval_seconds;
394408
if (interval <= 0) {
395409
LOG(WARNING) << "update compaction check interval config is illegal: " << interval << ", force set to 1";
@@ -401,6 +415,12 @@ void* StorageEngine::_update_compaction_thread_callback(void* arg, DataDir* data
401415
!_options.update_mem_tracker->any_limit_exceeded()) {
402416
break;
403417
}
418+
LOG_EVERY_N(INFO, 10) << "Update compaction still suspended due to memory limit"
419+
<< ", Compaction mem tracker limit exceeded: "
420+
<< _options.compaction_mem_tracker->any_limit_exceeded()
421+
<< ", Update mem tracker limit exceeded: "
422+
<< _options.update_mem_tracker->any_limit_exceeded()
423+
<< ", data_dir: " << data_dir->path();
404424
} while (true);
405425
}
406426

0 commit comments

Comments
 (0)