print throttled size in debug log

This commit is contained in:
ZenoWang
2024-02-27 05:22:22 +00:00
committed by ob-robot
parent d1d1af5969
commit 9b36886e82
7 changed files with 25 additions and 11 deletions

View File

@ -190,7 +190,7 @@ ObMdsThrottleGuard::~ObMdsThrottleGuard()
MDS_LOG_RET(ERROR, OB_ERR_UNEXPECTED, "throttle tool is unexpected nullptr", KP(throttle_tool_));
} else if (throttle_tool_->is_throttling<ObTenantMdsAllocator>(share_ti_guard, module_ti_guard)) {
(void)TxShareMemThrottleUtil::do_throttle<ObTenantMdsAllocator>(
for_replay_, abs_expire_time_, *throttle_tool_, share_ti_guard, module_ti_guard);
for_replay_, abs_expire_time_, share::mds_throttled_alloc(), *throttle_tool_, share_ti_guard, module_ti_guard);
if (throttle_tool_->still_throttling<ObTenantMdsAllocator>(share_ti_guard, module_ti_guard)) {
(void)throttle_tool_->skip_throttle<ObTenantMdsAllocator>(

View File

@ -87,6 +87,7 @@ public:
template <typename ALLOCATOR>
static int do_throttle(const bool for_replay,
const int64_t abs_expire_time,
const int64_t throttle_memory_size,
TxShareThrottleTool &throttle_tool,
ObThrottleInfoGuard &share_ti_guard,
ObThrottleInfoGuard &module_ti_guard)
@ -142,7 +143,7 @@ public:
module_ti_guard,
has_printed_lbt);
}
PrintThrottleUtil::print_throttle_statistic(ret, ALLOCATOR::throttle_unit_name(), sleep_time);
PrintThrottleUtil::print_throttle_statistic(ret, ALLOCATOR::throttle_unit_name(), sleep_time, throttle_memory_size);
if (for_replay && sleep_time > 0) {
// avoid print replay_timeout

View File

@ -126,8 +126,12 @@ ObTxDataThrottleGuard::~ObTxDataThrottleGuard()
if (OB_ISNULL(throttle_tool_)) {
MDS_LOG_RET(ERROR, OB_ERR_UNEXPECTED, "throttle tool is unexpected nullptr", KP(throttle_tool_));
} else if (throttle_tool_->is_throttling<ObTenantTxDataAllocator>(share_ti_guard, module_ti_guard)) {
(void)TxShareMemThrottleUtil::do_throttle<ObTenantTxDataAllocator>(
for_replay_, abs_expire_time_, *throttle_tool_, share_ti_guard, module_ti_guard);
(void)TxShareMemThrottleUtil::do_throttle<ObTenantTxDataAllocator>(for_replay_,
abs_expire_time_,
share::tx_data_throttled_alloc(),
*throttle_tool_,
share_ti_guard,
module_ti_guard);
if (throttle_tool_->still_throttling<ObTenantTxDataAllocator>(share_ti_guard, module_ti_guard)) {
(void)throttle_tool_->skip_throttle<ObTenantTxDataAllocator>(