fix: compatible with oracle 'sampled' mode keyword
This commit is contained in:
parent
c85a1348ba
commit
637742e243
@ -1127,7 +1127,7 @@ bool ObKvFeatureModeParser::parse(const char *str, uint8_t *arr, int64_t len)
|
||||
|
||||
bool ObConfigIndexStatsModeChecker::check(const ObConfigItem &t) const {
|
||||
const ObString tmp_str(t.str());
|
||||
return 0 == tmp_str.case_compare("SAMPLE") || 0 == tmp_str.case_compare("ALL");
|
||||
return 0 == tmp_str.case_compare("SAMPLED") || 0 == tmp_str.case_compare("ALL");
|
||||
}
|
||||
|
||||
} // end of namepace common
|
||||
|
@ -268,7 +268,7 @@ void ObIndexUsageInfoMgr::refresh_config()
|
||||
if (OB_LIKELY(tenant_config.is_valid())) {
|
||||
max_entries_ = tenant_config->_iut_max_entries.get();
|
||||
is_enabled_ = tenant_config->_iut_enable;
|
||||
is_sample_mode_ = tenant_config->_iut_stat_collection_type.get_value_string().case_compare("SAMPLE") == 0;
|
||||
is_sample_mode_ = tenant_config->_iut_stat_collection_type.get_value_string().case_compare("SAMPLED") == 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -380,7 +380,7 @@ void ObIndexUsageRefreshConfTask::runTimerTask()
|
||||
if (OB_LIKELY(tenant_config.is_valid())) {
|
||||
mgr_->set_max_entries(tenant_config->_iut_max_entries.get());
|
||||
mgr_->set_is_enabled(tenant_config->_iut_enable);
|
||||
mgr_->set_is_sample_mode(tenant_config->_iut_stat_collection_type.get_value_string().case_compare("SAMPLE") == 0);
|
||||
mgr_->set_is_sample_mode(tenant_config->_iut_stat_collection_type.get_value_string().case_compare("SAMPLED") == 0);
|
||||
LOG_TRACE("success to refresh index usage config.",
|
||||
K(mgr_->get_max_entries()), K(mgr_->get_is_enabled()), K(mgr_->get_is_sample_mode()));
|
||||
}
|
||||
|
@ -1793,9 +1793,9 @@ DEF_INT(_iut_max_entries, OB_TENANT_PARAMETER, "30000", "[0,]",
|
||||
"maximum of index entries to be monitoring.",
|
||||
ObParameterAttr(Section::TENANT, Source::DEFAULT, EditLevel::DYNAMIC_EFFECTIVE))
|
||||
|
||||
DEF_STR_WITH_CHECKER(_iut_stat_collection_type, OB_TENANT_PARAMETER, "SAMPLE",
|
||||
DEF_STR_WITH_CHECKER(_iut_stat_collection_type, OB_TENANT_PARAMETER, "SAMPLED",
|
||||
common::ObConfigIndexStatsModeChecker,
|
||||
"specify index table usage stat collection type, values: SAMPLE, ALL",
|
||||
"specify index table usage stat collection type, values: SAMPLED, ALL",
|
||||
ObParameterAttr(Section::TENANT, Source::DEFAULT, EditLevel::DYNAMIC_EFFECTIVE));
|
||||
|
||||
DEF_INT(optimizer_index_cost_adj, OB_TENANT_PARAMETER, "0", "[0,100]",
|
||||
|
Loading…
x
Reference in New Issue
Block a user