diff --git a/src/share/io/io_schedule/ob_io_mclock.cpp b/src/share/io/io_schedule/ob_io_mclock.cpp index 18a5cd503c..413efa1b03 100644 --- a/src/share/io/io_schedule/ob_io_mclock.cpp +++ b/src/share/io/io_schedule/ob_io_mclock.cpp @@ -519,7 +519,7 @@ double ObTenantIOClock::get_weight_scale(const int64_t queue_index) int64_t ObTenantIOClock::calc_iops(const int64_t iops, const int64_t percentage) { - return max(1, static_cast(static_cast(iops) * percentage / 100)); + return static_cast(iops) / 100 * percentage >= INT64_MAX ? INT64_MAX : static_cast(static_cast(iops) / 100 * percentage); } int64_t ObTenantIOClock::calc_weight(const int64_t weight, const int64_t percentage) @@ -533,4 +533,4 @@ void ObTenantIOClock::stop_clock(const uint64_t index) if (index < group_clocks_.count() && index >= 0) { group_clocks_.at(index).stop(); } -} \ No newline at end of file +} diff --git a/src/share/io/ob_io_manager.cpp b/src/share/io/ob_io_manager.cpp index 3c57ee4bb9..6c2877829a 100644 --- a/src/share/io/ob_io_manager.cpp +++ b/src/share/io/ob_io_manager.cpp @@ -883,7 +883,7 @@ int ObTenantIOManager::update_basic_io_config(const ObTenantIOConfig &io_config) if (OB_FAIL(io_clock_->update_io_clocks(io_config_))) { LOG_WARN("refresh io clock failed", K(ret), K(io_config_)); } else { - LOG_INFO("update basic io config success", K(tenant_id_), K(io_config_), K(io_config)); + LOG_INFO("update basic io config success", K(tenant_id_), K(io_config_), K(io_config), K(io_clock_)); } } }