add trace for allocate link buffer

This commit is contained in:
18523270951@163.com
2023-08-09 02:54:39 +00:00
committed by ob-robot
parent b6e343acdb
commit 9bbd0b3c26
2 changed files with 7 additions and 0 deletions

View File

@ -635,6 +635,7 @@ class EventTable
EN_PX_JOIN_FILTER_NOT_MERGE_MSG = 610,
EN_PX_P2P_MSG_REG_DM_FAILED= 611,
EN_PX_JOIN_FILTER_HOLD_MSG = 612,
EN_PX_DTL_TRACE_LOG_ENABLE = 613,
// please add new trace point after 700 or before 600
// Compaction Related 700-750

View File

@ -18,6 +18,7 @@
#include "observer/omt/ob_tenant_config_mgr.h"
#include "src/sql/dtl/ob_dtl_tenant_mem_manager.h"
#include "share/ob_occam_time_guard.h"
#include "lib/utility/ob_tracepoint.h"
using namespace oceanbase::common;
using namespace oceanbase::lib;
@ -135,6 +136,11 @@ ObDtlLinkedBuffer *ObDtlChannelMemManager::alloc(int64_t chid, int64_t size)
if (nullptr != allocated_buf) {
increase_alloc_cnt();
}
uint64_t opt = std::abs(EVENT_CALL(EventTable::EN_PX_DTL_TRACE_LOG_ENABLE));
if (0 != opt) {
share::ObTaskController::get().allow_next_syslog();
LOG_INFO("alloc dtl buffer", KP(allocated_buf));
}
LOG_TRACE("channel memory status", K(get_alloc_cnt()), K(get_free_cnt()),
K(get_free_queue_length()), K(get_max_tenant_memory_limit_size()), K(get_max_dtl_memory_size()),
K(get_used_memory_size()), K(max_mem_percent_), KP(allocated_buf), K(seqno_));