Merge pull request #15887 from taosdata/fix/mnode

enh: adjust the default value of supportVnodes parameters
This commit is contained in:
Shengliang Guan 2022-08-09 16:19:41 +08:00 committed by GitHub
commit 500a0ca56e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 6 deletions

View File

@ -355,7 +355,11 @@ static int32_t taosAddSystemCfg(SConfig *pCfg) {
static int32_t taosAddServerCfg(SConfig *pCfg) { static int32_t taosAddServerCfg(SConfig *pCfg) {
if (cfgAddDir(pCfg, "dataDir", tsDataDir, 0) != 0) return -1; if (cfgAddDir(pCfg, "dataDir", tsDataDir, 0) != 0) return -1;
if (cfgAddFloat(pCfg, "minimalDataDirGB", 2.0f, 0.001f, 10000000, 0) != 0) return -1; if (cfgAddFloat(pCfg, "minimalDataDirGB", 2.0f, 0.001f, 10000000, 0) != 0) return -1;
tsNumOfSupportVnodes = tsNumOfCores * 2;
tsNumOfSupportVnodes = TMAX(tsNumOfSupportVnodes, 2);
if (cfgAddInt32(pCfg, "supportVnodes", tsNumOfSupportVnodes, 0, 4096, 0) != 0) return -1; if (cfgAddInt32(pCfg, "supportVnodes", tsNumOfSupportVnodes, 0, 4096, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "maxShellConns", tsMaxShellConns, 10, 50000000, 0) != 0) return -1; if (cfgAddInt32(pCfg, "maxShellConns", tsMaxShellConns, 10, 50000000, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "statusInterval", tsStatusInterval, 1, 30, 0) != 0) return -1; if (cfgAddInt32(pCfg, "statusInterval", tsStatusInterval, 1, 30, 0) != 0) return -1;
if (cfgAddInt32(pCfg, "minSlidingTime", tsMinSlidingTime, 10, 1000000, 0) != 0) return -1; if (cfgAddInt32(pCfg, "minSlidingTime", tsMinSlidingTime, 10, 1000000, 0) != 0) return -1;

View File

@ -24,12 +24,9 @@ class TDSimClient:
self.cfgDict = { self.cfgDict = {
"numOfLogLines": "100000000", "numOfLogLines": "100000000",
"numOfThreadsPerCore": "2.0",
"locale": "en_US.UTF-8", "locale": "en_US.UTF-8",
"charset": "UTF-8", "charset": "UTF-8",
"asyncLog": "0", "asyncLog": "0",
"anyIp": "0",
"sdbDebugFlag": "135",
"rpcDebugFlag": "135", "rpcDebugFlag": "135",
"tmrDebugFlag": "131", "tmrDebugFlag": "131",
"cDebugFlag": "135", "cDebugFlag": "135",

View File

@ -30,7 +30,6 @@ class TDSimClient:
self.path = path self.path = path
self.cfgDict = { self.cfgDict = {
"numOfLogLines": "100000000", "numOfLogLines": "100000000",
"numOfThreadsPerCore": "2.0",
"locale": "en_US.UTF-8", "locale": "en_US.UTF-8",
"charset": "UTF-8", "charset": "UTF-8",
"asyncLog": "0", "asyncLog": "0",
@ -40,6 +39,7 @@ class TDSimClient:
"udebugFlag": "143", "udebugFlag": "143",
"jnidebugFlag": "143", "jnidebugFlag": "143",
"qdebugFlag": "143", "qdebugFlag": "143",
"supportVnodes": "1024",
"telemetryReporting": "0", "telemetryReporting": "0",
} }
@ -117,8 +117,6 @@ class TDDnode:
self.valgrind = 0 self.valgrind = 0
self.remoteIP = "" self.remoteIP = ""
self.cfgDict = { self.cfgDict = {
"walLevel": "2",
"fsync": "1000",
"monitor": "0", "monitor": "0",
"maxShellConns": "30000", "maxShellConns": "30000",
"locale": "en_US.UTF-8", "locale": "en_US.UTF-8",
@ -139,6 +137,7 @@ class TDDnode:
"qdebugFlag": "143", "qdebugFlag": "143",
"numOfLogLines": "100000000", "numOfLogLines": "100000000",
"statusInterval": "1", "statusInterval": "1",
"supportVnodes": "1024",
"telemetryReporting": "0" "telemetryReporting": "0"
} }