[scn] fix failure of mittest after refresh feature scn
This commit is contained in:
@ -98,7 +98,6 @@
|
||||
#include "share/ob_server_blacklist.h"
|
||||
#include "share/ob_primary_standby_service.h" // ObPrimaryStandbyService
|
||||
#include "logservice/palf/election/interface/election.h"
|
||||
#include "storage/ddl/ob_ddl_redo_log_writer.h"
|
||||
|
||||
using namespace oceanbase::lib;
|
||||
using namespace oceanbase::common;
|
||||
@ -365,8 +364,6 @@ int ObServer::init(const ObServerOptions &opts, const ObPLogWriterCfg &log_cfg)
|
||||
LOG_ERROR("init ASH failed", KR(ret));
|
||||
} else if (OB_FAIL(ObServerBlacklist::get_instance().init(self_addr_, net_frame_.get_req_transport()))) {
|
||||
LOG_ERROR("init server blacklist failed", KR(ret));
|
||||
} else if (OB_FAIL(ObDDLRedoLogWriter::get_instance().init())) {
|
||||
LOG_WARN("init DDL redo log writer failed", KR(ret));
|
||||
} else {
|
||||
GDS.set_rpc_proxy(&rs_rpc_proxy_);
|
||||
}
|
||||
@ -495,6 +492,10 @@ void ObServer::destroy()
|
||||
fin_oss_env();
|
||||
FLOG_INFO("oss storage destroyed");
|
||||
|
||||
FLOG_INFO("begin to destroy cos storage");
|
||||
fin_cos_env();
|
||||
FLOG_INFO("cos storage destroyed");
|
||||
|
||||
FLOG_INFO("begin to destroy io manager");
|
||||
ObIOManager::get_instance().destroy();
|
||||
FLOG_INFO("io manager destroyed");
|
||||
@ -1315,8 +1316,6 @@ int ObServer::init_config()
|
||||
// nop
|
||||
} else if (OB_FAIL(config_.strict_check_special())) {
|
||||
LOG_ERROR("some config setting is not valid", KR(ret));
|
||||
} else if (OB_FAIL(GMEMCONF.reload_config(config_))) {
|
||||
LOG_ERROR("reload memory config failed", KR(ret));
|
||||
} else if (OB_FAIL(set_running_mode())) {
|
||||
LOG_ERROR("set running mode failed", KR(ret));
|
||||
} else {
|
||||
@ -1364,7 +1363,9 @@ int ObServer::init_config()
|
||||
}
|
||||
|
||||
get_unis_global_compat_version() = GET_MIN_CLUSTER_VERSION();
|
||||
lib::g_runtime_enabled = true;
|
||||
if (GET_MIN_CLUSTER_VERSION() >= CLUSTER_VERSION_2100) {
|
||||
lib::g_runtime_enabled = true;
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
@ -1372,7 +1373,7 @@ int ObServer::init_config()
|
||||
int ObServer::set_running_mode()
|
||||
{
|
||||
int ret = OB_SUCCESS;
|
||||
const int64_t memory_limit = GMEMCONF.get_server_memory_limit();
|
||||
const int64_t memory_limit = GCONF.get_server_memory_limit();
|
||||
if (memory_limit < lib::ObRunningModeConfig::MINI_MEM_LOWER) {
|
||||
ret = OB_MACHINE_RESOURCE_NOT_ENOUGH;
|
||||
LOG_ERROR("memory limit too small", KR(ret), K(memory_limit));
|
||||
@ -1425,7 +1426,7 @@ int ObServer::init_pre_setting()
|
||||
|
||||
// total memory limit
|
||||
if (OB_SUCC(ret)) {
|
||||
const int64_t limit_memory = GMEMCONF.get_server_memory_limit();
|
||||
const int64_t limit_memory = config_.get_server_memory_limit();
|
||||
const int64_t reserved_memory = std::min(config_.cache_wash_threshold.get_value(),
|
||||
static_cast<int64_t>(static_cast<double>(limit_memory) * KVCACHE_FACTOR));
|
||||
const int64_t reserved_urgent_memory = config_.memory_reserved;
|
||||
@ -1500,7 +1501,7 @@ int ObServer::init_io()
|
||||
|
||||
if (OB_SUCC(ret)) {
|
||||
static const double IO_MEMORY_RATIO = 0.2;
|
||||
if (OB_FAIL(ObIOManager::get_instance().init(GMEMCONF.get_reserved_server_memory() * IO_MEMORY_RATIO))) {
|
||||
if (OB_FAIL(ObIOManager::get_instance().init(GCONF.get_reserved_server_memory() * IO_MEMORY_RATIO))) {
|
||||
LOG_ERROR("init io manager fail, ", KR(ret));
|
||||
} else {
|
||||
ObIOConfig io_config;
|
||||
@ -1741,6 +1742,7 @@ int ObServer::init_autoincrement_service()
|
||||
&sql_proxy_,
|
||||
&srv_rpc_proxy_,
|
||||
&schema_service_,
|
||||
location_service_,
|
||||
net_frame_.get_req_transport()))) {
|
||||
LOG_ERROR("init autoincrement_service_ fail", KR(ret));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user