diff --git a/src/plugins/monitor/src/monMain.c b/src/plugins/monitor/src/monMain.c index 1ff2f0ef8dd837496078742b7c95ccd4264acd45..bd0e0152058dc046857d91559170407a73f68d53 100644 --- a/src/plugins/monitor/src/monMain.c +++ b/src/plugins/monitor/src/monMain.c @@ -703,8 +703,8 @@ static int32_t monBuildMnodesTotalSql(char *sql) { for (int i = 0; i < num_fields; ++i) { if (strcmp(fields[i].name, "role") == 0) { int32_t charLen = monGetRowElemCharLen(fields[i], (char *)row[i]); - if (strncmp((char *)row[i], "master", charLen) == 0 || - strncmp((char *)row[i], "slave", charLen) == 0) { + if (strncmp((char *)row[i], "leader", charLen) == 0 || + strncmp((char *)row[i], "follower", charLen) == 0) { totalMnodesAlive += 1; } } @@ -794,8 +794,8 @@ static int32_t monGetVnodesTotalStats(char *ep, int32_t *totalVnodes, for (int i = 0; i < num_fields; ++i) { if (strcmp(fields[i].name, "status") == 0) { int32_t charLen = monGetRowElemCharLen(fields[i], (char *)row[i]); - if (strncmp((char *)row[i], "master", charLen) == 0 || - strncmp((char *)row[i], "slave", charLen) == 0) { + if (strncmp((char *)row[i], "leader", charLen) == 0 || + strncmp((char *)row[i], "follower", charLen) == 0) { *totalVnodesAlive += 1; } } diff --git a/src/sync/src/syncMain.c b/src/sync/src/syncMain.c index be35f3aaf9ed80fb66414e918e920fcd714620e1..3f5b2e12e2de2167b3e3e2c6da84dbc803874d40 100644 --- a/src/sync/src/syncMain.c +++ b/src/sync/src/syncMain.c @@ -68,8 +68,8 @@ char* syncRole[] = { "offline", "unsynced", "syncing", - "slave", - "master" + "follower", + "leader" }; char *syncStatus[] = { diff --git a/tests/pytest/client/client.py b/tests/pytest/client/client.py index 9a155a4df9ec1f4b6b1ce4860a75938c5edc7731..45fd2e318bbee6f9c43f3365fe62406e273b60cc 100644 --- a/tests/pytest/client/client.py +++ b/tests/pytest/client/client.py @@ -49,7 +49,7 @@ class TDTestCase: ret = tdSql.query('show mnodes') tdSql.checkRows(1) - tdSql.checkData(0, 2, "master") + tdSql.checkData(0, 2, "leader") role_time = tdSql.getData(0, 3) create_time = tdSql.getData(0, 4) @@ -72,7 +72,7 @@ class TDTestCase: ret = tdSql.query('show vnodes "{}"'.format(dnodeEndpoint)) tdSql.checkRows(1) tdSql.checkData(0, 0, 2) - tdSql.checkData(0, 1, "master") + tdSql.checkData(0, 1, "leader") def stop(self): tdSql.close() diff --git a/tests/pytest/cluster/changeReplicaTest.py b/tests/pytest/cluster/changeReplicaTest.py index 7fa68edbfee2db599076befdf9bed5f4b4be3c83..a7b357cc579a4dfb82eceb149861bc00388adf99 100644 --- a/tests/pytest/cluster/changeReplicaTest.py +++ b/tests/pytest/cluster/changeReplicaTest.py @@ -30,22 +30,22 @@ class ClusterTestcase: tdSql.execute("use %s" % ctest.dbName) tdSql.query("show vgroups") for i in range(10): - tdSql.checkData(i, 5, "master") + tdSql.checkData(i, 5, "leader") tdSql.execute("alter database %s replica 2" % ctest.dbName) tdLog.sleep(30) tdSql.query("show vgroups") for i in range(10): - tdSql.checkData(i, 5, "master") - tdSql.checkData(i, 7, "slave") + tdSql.checkData(i, 5, "leader") + tdSql.checkData(i, 7, "follower") tdSql.execute("alter database %s replica 3" % ctest.dbName) tdLog.sleep(30) tdSql.query("show vgroups") for i in range(10): - tdSql.checkData(i, 5, "master") - tdSql.checkData(i, 7, "slave") - tdSql.checkData(i, 9, "slave") + tdSql.checkData(i, 5, "leader") + tdSql.checkData(i, 7, "follower") + tdSql.checkData(i, 9, "follower") ct = ClusterTestcase() ct.run() \ No newline at end of file diff --git a/tests/pytest/manualTest/TD-5114/checkClusterStatus.py b/tests/pytest/manualTest/TD-5114/checkClusterStatus.py index c6bff305a5b3317d03a793c9634b1ea19b3b7217..213d6b87abb9294c637039f3a2ce44f84461e937 100644 --- a/tests/pytest/manualTest/TD-5114/checkClusterStatus.py +++ b/tests/pytest/manualTest/TD-5114/checkClusterStatus.py @@ -53,7 +53,7 @@ class TwoClients: tdSql.query("show mnodes") tdSql.checkRows(3) - roles = "master slave" + roles = "leader follower" for i in range(tdSql.queryRows): if (tdSql.queryResult[i][2] in roles ): ep = tdSql.queryResult[i][1] diff --git a/tests/script/general/db/alter_tables_d2.sim b/tests/script/general/db/alter_tables_d2.sim index f74f98d571e49090e2c25d2371a0e0c268c9a3ee..41d72e35d3ba35ad9fd3741ae4c9abe8ea075d2b 100644 --- a/tests/script/general/db/alter_tables_d2.sim +++ b/tests/script/general/db/alter_tables_d2.sim @@ -109,7 +109,7 @@ sql show mnodes -x step1 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step2 endi @@ -186,7 +186,7 @@ sql show mnodes -x step3 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step3 endi @@ -323,7 +323,7 @@ sql show mnodes -x step9 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step9 endi @@ -419,7 +419,7 @@ sql show mnodes -x step10 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step10 endi @@ -482,7 +482,7 @@ sql show mnodes -x step1xx print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1xx endi diff --git a/tests/script/general/db/alter_tables_v1.sim b/tests/script/general/db/alter_tables_v1.sim index 20c4c7336312b7eb701fe04c6b4158f466e43146..8708d764e43e41325e3ed7d80d45c34d0a3d1031 100644 --- a/tests/script/general/db/alter_tables_v1.sim +++ b/tests/script/general/db/alter_tables_v1.sim @@ -62,7 +62,7 @@ sql show mnodes -x step2 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step2 endi @@ -115,7 +115,7 @@ sql show mnodes -x step5 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step5 endi @@ -185,7 +185,7 @@ sql show mnodes -x step7 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step7 endi @@ -240,7 +240,7 @@ sql show mnodes -x step9 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step9 endi @@ -314,7 +314,7 @@ sql show mnodes -x step10 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step10 endi @@ -369,7 +369,7 @@ sql show mnodes -x step12 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step12 endi diff --git a/tests/script/general/db/alter_tables_v4.sim b/tests/script/general/db/alter_tables_v4.sim index 10bb4e108bf7fc6c879e230565dad29599f15549..02816097ed2235b1535a0629407cc9704862d84a 100644 --- a/tests/script/general/db/alter_tables_v4.sim +++ b/tests/script/general/db/alter_tables_v4.sim @@ -81,7 +81,7 @@ sql show mnodes -x step3 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step3 endi @@ -155,7 +155,7 @@ sql show mnodes -x step5 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step5 endi @@ -287,7 +287,7 @@ sql show mnodes -x step9 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step9 endi @@ -381,7 +381,7 @@ sql show mnodes -x step10 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step10 endi @@ -441,7 +441,7 @@ sql show mnodes -x step12 print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step12 endi diff --git a/tests/script/general/db/delete.sim b/tests/script/general/db/delete.sim index 4384044885e7c6a660079551b1190481ace3554e..80ec812c74135addc1d0c072b8e7ebd6be8e6f86 100644 --- a/tests/script/general/db/delete.sim +++ b/tests/script/general/db/delete.sim @@ -57,7 +57,7 @@ step3: sql show mnodes print dnode1 role $data2_1 -if $data2_1 != master then +if $data2_1 != leader then goto step3 endi diff --git a/tests/script/general/wal/sync.sim b/tests/script/general/wal/sync.sim index 3a8952391818bc02244f7455f694b6c1fe834288..bd9ed574a96b1afbaaf3f68a4ca41700f40434a2 100644 --- a/tests/script/general/wal/sync.sim +++ b/tests/script/general/wal/sync.sim @@ -54,13 +54,13 @@ print mnode2Role $mnode2Role $mnode3Role = $data2_3 print mnode3Role $mnode3Role -if $mnode1Role != master then +if $mnode1Role != leader then goto show1 endi -if $mnode2Role != slave then +if $mnode2Role != follower then goto show1 endi -if $mnode3Role != slave then +if $mnode3Role != follower then goto show1 endi diff --git a/tests/script/issue/TD-2677.sim b/tests/script/issue/TD-2677.sim index 8d2058a3851e456dd85f8d6a295ce45b7a6fd3bd..db61aca8111c03920fa780ebfd88592c89695623 100644 --- a/tests/script/issue/TD-2677.sim +++ b/tests/script/issue/TD-2677.sim @@ -54,13 +54,13 @@ print mnode2Role $mnode2Role $mnode3Role = $data2_3 print mnode3Role $mnode3Role -if $mnode1Role != master then +if $mnode1Role != leader then goto step1 endi -if $mnode2Role != slave then +if $mnode2Role != follower then goto step1 endi -if $mnode3Role != slave then +if $mnode3Role != follower then goto step1 endi diff --git a/tests/script/issue/TD-2680.sim b/tests/script/issue/TD-2680.sim index 631332160fe1ede876ef2b966dfb1963ac7351ca..4f1bd63dd825f266fc5b8f11d078f711a90e6388 100644 --- a/tests/script/issue/TD-2680.sim +++ b/tests/script/issue/TD-2680.sim @@ -67,7 +67,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/issue/TD-2713.sim b/tests/script/issue/TD-2713.sim index b66c55b9b95f67eb2478791e8ee45ffd503b12be..f2c0bc9eb52ea58f488ab81d1c509748437b3a50 100644 --- a/tests/script/issue/TD-2713.sim +++ b/tests/script/issue/TD-2713.sim @@ -60,13 +60,13 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi -if $data2_2 != slave then +if $data2_2 != follower then goto step1 endi -if $data2_3 != slave then +if $data2_3 != follower then goto step1 endi diff --git a/tests/script/issue/TD-3300.sim b/tests/script/issue/TD-3300.sim index 0745ceb8490567b508397b3e99d4748dc41c8971..8ff3af5895a22c913bb888e865099cf840ceb17a 100644 --- a/tests/script/issue/TD-3300.sim +++ b/tests/script/issue/TD-3300.sim @@ -76,10 +76,10 @@ endi if $data06 != 2 then return -1 endi -if $data05 != master then +if $data05 != leader then return -1 endi -if $data07 != slave then +if $data07 != follower then return -1 endi @@ -125,10 +125,10 @@ endi if $data06 != 2 then goto step4 endi -if $data05 != master then +if $data05 != leader then goto step4 endi -if $data07 != slave then +if $data07 != follower then goto step4 endi @@ -189,7 +189,7 @@ endi if $data05 != offline then goto step5 endi -if $data07 != master then +if $data07 != leader then goto step5 endi @@ -251,10 +251,10 @@ endi if $data06 != 2 then goto step6 endi -if $data05 != slave then +if $data05 != follower then goto step6 endi -if $data07 != master then +if $data07 != leader then goto step6 endi @@ -337,7 +337,7 @@ endi if $data06 != 2 then goto step7 endi -if $data05 != master then +if $data05 != leader then goto step7 endi if $data07 != offline then @@ -422,10 +422,10 @@ endi if $data06 != 2 then goto step8 endi -if $data05 != master then +if $data05 != leader then goto step8 endi -if $data07 != slave then +if $data07 != follower then goto step8 endi @@ -521,7 +521,7 @@ endi if $data05 != offline then goto step7 endi -if $data07 != master then +if $data07 != leader then goto step7 endi diff --git a/tests/script/tmp/mnodes.sim b/tests/script/tmp/mnodes.sim index 8bca76c38b627ac6a6aa9eaae07a9126a9b19057..e9b03c84472f8c38808484a5adecbbeb9a05fe76 100644 --- a/tests/script/tmp/mnodes.sim +++ b/tests/script/tmp/mnodes.sim @@ -74,13 +74,13 @@ print mnode2Role $mnode2Role $mnode3Role = $data2_3 print mnode3Role $mnode3Role -if $mnode1Role != master then +if $mnode1Role != leader then goto step1 endi -if $mnode2Role != slave then +if $mnode2Role != follower then goto step1 endi -if $mnode3Role != slave then +if $mnode3Role != follower then goto step1 endi diff --git a/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync.sim b/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync.sim index dbd0e2bd87c099dca54aa33d609696cb2dc89381..f20c92b9827ef88f5e69f15195a028987be82d5d 100644 --- a/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync.sim +++ b/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync.sim @@ -1,6 +1,6 @@ # Test case describe: dnode1 is only mnode, dnode2/dnode3 are only vnode # step 1: start dnode1 -# step 2: start dnode2 and dnode3, and all added into cluster (Suppose dnode2 is master-vnode) +# step 2: start dnode2 and dnode3, and all added into cluster (Suppose dnode2 is leader-vnode) # step 2: create db, table, insert data, and Falling disc into file (control only one file, e.g. 1841) # step 3: insert old data(now-20d) and new data(now-40d), control data rows in order to save in cache, not falling disc # step 4: stop dnode2, so date rows falling disc, generate two new files 1840, 1842 in dnode2 @@ -145,7 +145,7 @@ if $dnode2Status != ready then goto wait_dnode3_offline endi -sleep $sleepTimer # waitting for move master vnode of dnode2 to dnode3 +sleep $sleepTimer # waitting for move leader vnode of dnode2 to dnode3 # check using select sql select count(*) from $stb print data00 $data00 diff --git a/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync_second.sim b/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync_second.sim index e15edb3f3d444b7407244b8cf3fa781ba36357d6..a7380a8de98d174e9e272d0c2e2782f95b4d0d44 100644 --- a/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync_second.sim +++ b/tests/script/unique/arbitrator/dn2_mn1_cache_file_sync_second.sim @@ -1,6 +1,6 @@ # Test case describe: dnode1 is only mnode, dnode2/dnode3 are only vnode # step 1: start dnode1 -# step 2: start dnode2 and dnode3, and all added into cluster (Suppose dnode2 is master-vnode) +# step 2: start dnode2 and dnode3, and all added into cluster (Suppose dnode2 is leader-vnode) # step 3: create db, table, insert data, and Falling disc into file (control only one file, e.g. 1841) # step 4: insert old data(now-20d) and new data(now-40d), control data rows in order to save in cache, not falling disc # step 5: stop dnode2, so date rows falling disc, generate two new files 1840, 1842 in dnode2 diff --git a/tests/script/unique/arbitrator/dn3_mn1_r2_vnode_delDir.sim b/tests/script/unique/arbitrator/dn3_mn1_r2_vnode_delDir.sim index 96fde9061a0648d69386cb7f5c23450dea6aad7e..3f5bcc5da989e6f5368411b18c0956d1868b6999 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_r2_vnode_delDir.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_r2_vnode_delDir.sim @@ -144,7 +144,7 @@ if $dnode3Vtatus != offline then sleep 2000 goto wait_dnode3_vgroup_offline endi -if $dnode2Vtatus != master then +if $dnode2Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_offline endi @@ -209,11 +209,11 @@ $dnode2Vtatus = $data7_2 print dnode2Vtatus: $dnode3Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode3Vtatus != slave then +if $dnode3Vtatus != follower then sleep 2000 goto wait_dnode3_vgroup_slave endi -if $dnode2Vtatus != master then +if $dnode2Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_slave endi @@ -325,11 +325,11 @@ $dnode2Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode2_vgroup_slave endi -if $dnode2Vtatus != slave then +if $dnode2Vtatus != follower then sleep 2000 goto wait_dnode2_vgroup_slave endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_r3_vnode_delDir.sim b/tests/script/unique/arbitrator/dn3_mn1_r3_vnode_delDir.sim index da76cc467b7813586c98761319a01eb1f2ed6bb6..f0d2b41ce8ffd470278931ea07ff4fe3d21f3546 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_r3_vnode_delDir.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_r3_vnode_delDir.sim @@ -146,7 +146,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi @@ -211,11 +211,11 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != slave then +if $dnode4Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_slave endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_slave endi @@ -330,11 +330,11 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_master endi -if $dnode3Vtatus != slave then +if $dnode3Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_master endi @@ -393,11 +393,11 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_master_2 endi -if $dnode3Vtatus != slave then +if $dnode3Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_master_2 endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_vnode_change.sim b/tests/script/unique/arbitrator/dn3_mn1_vnode_change.sim index 6d81effab63bb52801ab51e53ee1147326b3e851..53a1ce04fa3876ff56f931570c98b896896e2737 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_vnode_change.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_vnode_change.sim @@ -145,7 +145,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi @@ -218,11 +218,11 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != slave then +if $dnode4Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_slave endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_slave endi @@ -292,7 +292,7 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_master endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_offline.sim b/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_offline.sim index d22aca07cbd3d3c6a902076103c9759209c6a966..ba15bb42d599cef7de137db2af386de57f9e8005 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_offline.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_offline.sim @@ -151,7 +151,7 @@ if $dnode3Vtatus != offline then sleep 2000 goto wait_dnode3_vgroup_offline endi -if $dnode2Vtatus != master then +if $dnode2Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_offline endi @@ -237,11 +237,11 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode2Vtatus = $data5_2 $dnode3Vtatus = $data7_2 -if $dnode2Vtatus != master then +if $dnode2Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_slave endi -if $dnode3Vtatus != slave then +if $dnode3Vtatus != follower then sleep 2000 goto wait_dnode3_vgroup_slave endi @@ -320,7 +320,7 @@ if $dnode2Vtatus != offline then sleep 2000 goto wait_dnode3_vgroup_master endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_master endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_online.sim b/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_online.sim index 884a43bce12d1bc2c137bab17b0e780c521e327c..119cb418dbfc478fb648397744f6e334567affd9 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_online.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_vnode_corruptFile_online.sim @@ -203,7 +203,7 @@ if $dnode2Vtatus != offline then sleep 2000 goto wait_dnode3_vgroup_master endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_master endi @@ -328,11 +328,11 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode2Vtatus = $data7_2 $dnode3Vtatus = $data5_2 -if $dnode2Vtatus != slave then +if $dnode2Vtatus != follower then sleep 2000 goto wait_dnode3_vgroup_master_1 endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_master_1 endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_vnode_createErrData_online.sim b/tests/script/unique/arbitrator/dn3_mn1_vnode_createErrData_online.sim index 3c74de49166067624335937d0e0486924b9fdb4f..f393e4afbac4fdeb9eaba639be34554a38c9c882 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_vnode_createErrData_online.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_vnode_createErrData_online.sim @@ -165,7 +165,7 @@ if $dnode2Vtatus != offline then sleep 2000 goto wait_dnode3_vgroup_master endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_master endi @@ -290,11 +290,11 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode2Vtatus = $data7_2 $dnode3Vtatus = $data5_2 -if $dnode2Vtatus != slave then +if $dnode2Vtatus != follower then sleep 2000 goto wait_dnode3_vgroup_master_1 endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_master_1 endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_vnode_delDir.sim b/tests/script/unique/arbitrator/dn3_mn1_vnode_delDir.sim index d0399222f14cc8b8d7ac12ebca8b91549c34942d..00ab574e0783e09906bd5c561c00a7c935720e82 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_vnode_delDir.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_vnode_delDir.sim @@ -148,7 +148,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi @@ -206,11 +206,11 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != slave then +if $dnode4Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_slave endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_slave endi @@ -306,11 +306,11 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_slave endi -if $dnode3Vtatus != slave then +if $dnode3Vtatus != follower then sleep 2000 goto wait_dnode3_vgroup_slave endi @@ -422,11 +422,11 @@ $dnode3Vtatus = $data7_2 print dnode4Vtatus: $dnode4Vtatus print dnode3Vtatus: $dnode3Vtatus -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode2_vgroup_slave endi -if $dnode3Vtatus != slave then +if $dnode3Vtatus != follower then sleep 2000 goto wait_dnode2_vgroup_slave endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_vnode_noCorruptFile_offline.sim b/tests/script/unique/arbitrator/dn3_mn1_vnode_noCorruptFile_offline.sim index 01534f9476a164d607620fcc93601c272b3e6042..370b19990ba9df97367a82144657dec35765951b 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_vnode_noCorruptFile_offline.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_vnode_noCorruptFile_offline.sim @@ -151,7 +151,7 @@ if $dnode3Vtatus != offline then sleep 2000 goto wait_dnode3_vgroup_offline endi -if $dnode2Vtatus != master then +if $dnode2Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_offline endi @@ -237,11 +237,11 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode2Vtatus = $data7_2 $dnode3Vtatus = $data5_2 -if $dnode2Vtatus != master then +if $dnode2Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_slave endi -if $dnode3Vtatus != slave then +if $dnode3Vtatus != follower then sleep 2000 goto wait_dnode3_vgroup_slave endi @@ -320,7 +320,7 @@ if $dnode2Vtatus != offline then sleep 2000 goto wait_dnode3_vgroup_master endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode3_vgroup_master endi diff --git a/tests/script/unique/arbitrator/dn3_mn1_vnode_nomaster.sim b/tests/script/unique/arbitrator/dn3_mn1_vnode_nomaster.sim index b9ee508f78602cee7d6c9f17dbc3e250e7014f72..35a7bf896610f39af3096b2b24942b2437c23051 100644 --- a/tests/script/unique/arbitrator/dn3_mn1_vnode_nomaster.sim +++ b/tests/script/unique/arbitrator/dn3_mn1_vnode_nomaster.sim @@ -268,7 +268,7 @@ if $dnode3Vtatus != offline then sleep 2000 goto wait_dnode2_vgroup_master endi -if $dnode2Vtatus != master then +if $dnode2Vtatus != leader then sleep 2000 goto wait_dnode2_vgroup_master endi diff --git a/tests/script/unique/arbitrator/dn3_mn2_killDnode.sim b/tests/script/unique/arbitrator/dn3_mn2_killDnode.sim index d90853d2e41e8384acad2f4dcd5a95eee8298745..d12b5ff3ad19b67766a475953e49a89454993aad 100644 --- a/tests/script/unique/arbitrator/dn3_mn2_killDnode.sim +++ b/tests/script/unique/arbitrator/dn3_mn2_killDnode.sim @@ -104,7 +104,7 @@ $mnode2Status = $data2_2 $mnode3Status = $data2_3 #$mnode4Status = $data2_4 -if $mnode1Status != master then +if $mnode1Status != leader then return -1 endi diff --git a/tests/script/unique/arbitrator/insert_duplicationTs.sim b/tests/script/unique/arbitrator/insert_duplicationTs.sim index 4af47ca336c188c3194b9fc64925073f8fb406c2..f10405eaa94a5b92f9fa6ae21c8cecb3f28a16b0 100644 --- a/tests/script/unique/arbitrator/insert_duplicationTs.sim +++ b/tests/script/unique/arbitrator/insert_duplicationTs.sim @@ -1,6 +1,6 @@ # Test case describe: dnode1 is only mnode, dnode2/dnode3 are only vnode # step 1: start dnode1 -# step 2: start dnode2 and dnode3, and all added into cluster (Suppose dnode2 is master-vnode) +# step 2: start dnode2 and dnode3, and all added into cluster (Suppose dnode2 is leader-vnode) # step 3: create db, table, insert data, and Falling disc into file (control only one file, e.g. 1841) # step 4: insert old data(now-15d) and new data(now+15d), control data rows in order to save in cache, not falling disc # step 5: stop dnode2, so date rows falling disc, generate two new files 1840, 1842 in dnode2 @@ -157,7 +157,7 @@ if $dnode3Status != ready then goto wait_dnode2_offline endi -sleep $sleepTimer # waitting for move master vnode of dnode2 to dnode3 +sleep $sleepTimer # waitting for move leader vnode of dnode2 to dnode3 # check using select sql select count(*) from $stb print data00 $data00 diff --git a/tests/script/unique/arbitrator/offline_replica2_alterTable_online.sim b/tests/script/unique/arbitrator/offline_replica2_alterTable_online.sim index 0adb6b475938c1aa37f56c20c5d6327c9f89d574..f3da076fde52a3b4eb6dd552ef8f3293d16349cd 100644 --- a/tests/script/unique/arbitrator/offline_replica2_alterTable_online.sim +++ b/tests/script/unique/arbitrator/offline_replica2_alterTable_online.sim @@ -146,7 +146,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica2_alterTag_online.sim b/tests/script/unique/arbitrator/offline_replica2_alterTag_online.sim index a0877ad89c20697e3b9a46f4512766fbd11439d8..6a4c92959c0d9649a934270d60a76e274254cd4f 100644 --- a/tests/script/unique/arbitrator/offline_replica2_alterTag_online.sim +++ b/tests/script/unique/arbitrator/offline_replica2_alterTag_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica2_createTable_online.sim b/tests/script/unique/arbitrator/offline_replica2_createTable_online.sim index 376484a0661d89fcd38f6be790437e10c6ef2761..d97638b6fc46ae6082f81b7e39682cbc961199e0 100644 --- a/tests/script/unique/arbitrator/offline_replica2_createTable_online.sim +++ b/tests/script/unique/arbitrator/offline_replica2_createTable_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica2_dropDb_online.sim b/tests/script/unique/arbitrator/offline_replica2_dropDb_online.sim index 9f21193400a8d7833afe8dbc5b4671c2f623778d..bb51700196424ef5e6b99ce5297bf047c4680d79 100644 --- a/tests/script/unique/arbitrator/offline_replica2_dropDb_online.sim +++ b/tests/script/unique/arbitrator/offline_replica2_dropDb_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica2_dropTable_online.sim b/tests/script/unique/arbitrator/offline_replica2_dropTable_online.sim index cb3bbb3a73f5213c346fc675049827730a6e3a01..592ad1b136f1ff22b859cd5a3972df08a9d888a0 100644 --- a/tests/script/unique/arbitrator/offline_replica2_dropTable_online.sim +++ b/tests/script/unique/arbitrator/offline_replica2_dropTable_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica3_alterTable_online.sim b/tests/script/unique/arbitrator/offline_replica3_alterTable_online.sim index 8a9995f89162883c6529a3cd8e63bc764884147b..b75a06874e6bfbf1120de324ac49f520678fb5d3 100644 --- a/tests/script/unique/arbitrator/offline_replica3_alterTable_online.sim +++ b/tests/script/unique/arbitrator/offline_replica3_alterTable_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica3_alterTag_online.sim b/tests/script/unique/arbitrator/offline_replica3_alterTag_online.sim index 6eed563bbc7c79ac35a782fbd9f2ccaa79f277d6..5a06ab44059da667ec0d4db677b544ec0e628e09 100644 --- a/tests/script/unique/arbitrator/offline_replica3_alterTag_online.sim +++ b/tests/script/unique/arbitrator/offline_replica3_alterTag_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica3_createTable_online.sim b/tests/script/unique/arbitrator/offline_replica3_createTable_online.sim index 2633d822c91d87ad6e5cc70370ac880fd397b889..31fe60aaac3d6db7dd72045a44ef1b252bd14aa2 100644 --- a/tests/script/unique/arbitrator/offline_replica3_createTable_online.sim +++ b/tests/script/unique/arbitrator/offline_replica3_createTable_online.sim @@ -151,7 +151,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica3_dropDb_online.sim b/tests/script/unique/arbitrator/offline_replica3_dropDb_online.sim index 3abfc401611044b5cc7a1fb9411e4fd461beca78..725ca1b6209a6227807043f5b570f7b62a6601ea 100644 --- a/tests/script/unique/arbitrator/offline_replica3_dropDb_online.sim +++ b/tests/script/unique/arbitrator/offline_replica3_dropDb_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/offline_replica3_dropTable_online.sim b/tests/script/unique/arbitrator/offline_replica3_dropTable_online.sim index f2acb8b90a35186395ab559ee428a182a2cba0d4..7dea6b24a9aa374c903724323967986b42a78603 100644 --- a/tests/script/unique/arbitrator/offline_replica3_dropTable_online.sim +++ b/tests/script/unique/arbitrator/offline_replica3_dropTable_online.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/replica_changeWithArbitrator.sim b/tests/script/unique/arbitrator/replica_changeWithArbitrator.sim index 2e5293d4c5560298fb972233970c9c9172adadb7..2caec9c5c16155af8ec0a015fb4ab3485b541f19 100644 --- a/tests/script/unique/arbitrator/replica_changeWithArbitrator.sim +++ b/tests/script/unique/arbitrator/replica_changeWithArbitrator.sim @@ -229,7 +229,7 @@ if $data2_1 != offline then sleep 2000 goto wait_dnode2_master endi -if $data2_2 != master then +if $data2_2 != leader then sleep 2000 goto wait_dnode2_master endi diff --git a/tests/script/unique/arbitrator/sync_replica2_alterTable_add.sim b/tests/script/unique/arbitrator/sync_replica2_alterTable_add.sim index a8c0e83cc1e5da61a473fa5b9753e90450e57bec..7ce878c63add94c7f49a78b5fd05f60f5bdb46ad 100644 --- a/tests/script/unique/arbitrator/sync_replica2_alterTable_add.sim +++ b/tests/script/unique/arbitrator/sync_replica2_alterTable_add.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica2_alterTable_drop.sim b/tests/script/unique/arbitrator/sync_replica2_alterTable_drop.sim index 951d26635b257d1c1d3ab81889b66bb909b8038b..83e31ff9ae66d6e4c951af3330043b33b011921d 100644 --- a/tests/script/unique/arbitrator/sync_replica2_alterTable_drop.sim +++ b/tests/script/unique/arbitrator/sync_replica2_alterTable_drop.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica2_dropDb.sim b/tests/script/unique/arbitrator/sync_replica2_dropDb.sim index e4e7f951881cf87c426c869774b2a3a548b29517..2272e63f0415472c32357b84310b043ad5c16b75 100644 --- a/tests/script/unique/arbitrator/sync_replica2_dropDb.sim +++ b/tests/script/unique/arbitrator/sync_replica2_dropDb.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica2_dropTable.sim b/tests/script/unique/arbitrator/sync_replica2_dropTable.sim index 0049dc6fba9bd33cd9c2e4f5b56510769dd0c60e..4f7588a43b97029caa4a48fad6f3817323be4635 100644 --- a/tests/script/unique/arbitrator/sync_replica2_dropTable.sim +++ b/tests/script/unique/arbitrator/sync_replica2_dropTable.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica3_alterTable_add.sim b/tests/script/unique/arbitrator/sync_replica3_alterTable_add.sim index 499089960100f0be445552112e2b2000164c1ca0..fa34a67b93fcc2277369133be48b26997edd0fe0 100644 --- a/tests/script/unique/arbitrator/sync_replica3_alterTable_add.sim +++ b/tests/script/unique/arbitrator/sync_replica3_alterTable_add.sim @@ -148,7 +148,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica3_alterTable_drop.sim b/tests/script/unique/arbitrator/sync_replica3_alterTable_drop.sim index 10bd4fc8bd3946871605f66493e15cdde28ec257..aefb849527da41645c3c7e815417bbc67fe74247 100644 --- a/tests/script/unique/arbitrator/sync_replica3_alterTable_drop.sim +++ b/tests/script/unique/arbitrator/sync_replica3_alterTable_drop.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica3_createTable.sim b/tests/script/unique/arbitrator/sync_replica3_createTable.sim index a0b391dd763f96fa6d340fad213943045b45ed69..0cea59f799b1bc7f28c004f2e609c86d4931fc1f 100644 --- a/tests/script/unique/arbitrator/sync_replica3_createTable.sim +++ b/tests/script/unique/arbitrator/sync_replica3_createTable.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica3_dnodeChang_DropAddAlterTableDropDb.sim b/tests/script/unique/arbitrator/sync_replica3_dnodeChang_DropAddAlterTableDropDb.sim index 68c6ecbd6ecf7c06b5ae595c16e5b7d4b89435bd..2f29dfb472cbec0a758f308b5b06223ce1ee9f36 100644 --- a/tests/script/unique/arbitrator/sync_replica3_dnodeChang_DropAddAlterTableDropDb.sim +++ b/tests/script/unique/arbitrator/sync_replica3_dnodeChang_DropAddAlterTableDropDb.sim @@ -146,7 +146,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi @@ -210,7 +210,7 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode4Vtatus = $data5_2 $dnode3Vtatus = $data7_2 -if $dnode4Vtatus != slave then +if $dnode4Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_slave endi @@ -243,7 +243,7 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode4Vtatus = $data5_2 $dnode3Vtatus = $data7_2 -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_master endi @@ -317,7 +317,7 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode4Vtatus = $data5_2 $dnode3Vtatus = $data7_2 -if $dnode4Vtatus != slave then +if $dnode4Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_slave_2 endi @@ -350,7 +350,7 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode4Vtatus = $data5_2 $dnode3Vtatus = $data7_2 -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_master_2 endi @@ -440,7 +440,7 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode4Vtatus = $data5_2 $dnode3Vtatus = $data7_2 -if $dnode4Vtatus != slave then +if $dnode4Vtatus != follower then sleep 2000 goto wait_dnode4_vgroup_slave_3 endi @@ -473,7 +473,7 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $dnode4Vtatus = $data5_2 $dnode3Vtatus = $data7_2 -if $dnode4Vtatus != master then +if $dnode4Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_master_3 endi diff --git a/tests/script/unique/arbitrator/sync_replica3_dropDb.sim b/tests/script/unique/arbitrator/sync_replica3_dropDb.sim index 83e53eaeeb16e0988b778ef0b2515dc12c397d38..4f61da9d9d60e2aecfea4118e7bba91b67b8ef7e 100644 --- a/tests/script/unique/arbitrator/sync_replica3_dropDb.sim +++ b/tests/script/unique/arbitrator/sync_replica3_dropDb.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/arbitrator/sync_replica3_dropTable.sim b/tests/script/unique/arbitrator/sync_replica3_dropTable.sim index 7496541b76da3245f034924e95fd468b61135aef..a74364a1581c07efbe93fbe58a5f32a611bf02ac 100644 --- a/tests/script/unique/arbitrator/sync_replica3_dropTable.sim +++ b/tests/script/unique/arbitrator/sync_replica3_dropTable.sim @@ -150,7 +150,7 @@ if $dnode4Vtatus != offline then sleep 2000 goto wait_dnode4_vgroup_offline endi -if $dnode3Vtatus != master then +if $dnode3Vtatus != leader then sleep 2000 goto wait_dnode4_vgroup_offline endi diff --git a/tests/script/unique/cluster/balance1.sim b/tests/script/unique/cluster/balance1.sim index 157fd8b06f303752de14f175107a8a9897a38ca0..204da264a1706e09269d9465a7d2c8cbec4fa86e 100644 --- a/tests/script/unique/cluster/balance1.sim +++ b/tests/script/unique/cluster/balance1.sim @@ -201,10 +201,10 @@ print dnode1 ==> $dnode1Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi -if $dnode3Role != slave then +if $dnode3Role != follower then return -1 endi @@ -245,7 +245,7 @@ print dnode1 ==> $dnode1Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi @@ -283,11 +283,11 @@ $dnode4Role = $data2_4 print dnode1 ==> $dnode1Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi -if $dnode4Role != slave then +if $dnode4Role != follower then return -1 endi diff --git a/tests/script/unique/cluster/balance2.sim b/tests/script/unique/cluster/balance2.sim index a267b8c380db9af8bc817a8f5483fd503085efd7..0f8281c78f08f6696a51552558f8e5d566070320 100644 --- a/tests/script/unique/cluster/balance2.sim +++ b/tests/script/unique/cluster/balance2.sim @@ -91,13 +91,13 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi -if $data2_2 != slave then +if $data2_2 != follower then goto step1 endi -if $data2_3 != slave then +if $data2_3 != follower then goto step1 endi @@ -235,17 +235,17 @@ print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi if $dnode2Role != null then return -1 endi -if $dnode3Role != slave then +if $dnode3Role != follower then return -1 endi -if $dnode4Role != slave then +if $dnode4Role != follower then return -1 endi @@ -288,7 +288,7 @@ print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi if $dnode2Role != null then @@ -298,7 +298,7 @@ if $dnode3Role != null then return -1 endi -if $dnode4Role != slave then +if $dnode4Role != follower then return -1 endi diff --git a/tests/script/unique/cluster/balance3.sim b/tests/script/unique/cluster/balance3.sim index 71d3130ec9b727bd7d366f3d10b79dfe67748618..67c8275c07a801096a1636747676722d05078cc8 100644 --- a/tests/script/unique/cluster/balance3.sim +++ b/tests/script/unique/cluster/balance3.sim @@ -76,13 +76,13 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi -if $data2_2 != slave then +if $data2_2 != follower then goto step1 endi -if $data2_3 != slave then +if $data2_3 != follower then goto step1 endi @@ -248,7 +248,7 @@ print dnode3 ==> $data2_3 print dnode4 ==> $data2_4 print dnode5 ==> $data2_5 -if $data2_4 != slave then +if $data2_4 != follower then goto show4 endi @@ -298,7 +298,7 @@ print dnode5 ==> $data2_5 print dnode6 ==> $data2_6 print dnode7 ==> $data2_7 -if $data2_5 != slave then +if $data2_5 != follower then goto show5 endi @@ -389,7 +389,7 @@ print dnode5 ==> $data2_5 print dnode6 ==> $data2_6 print dnode7 ==> $data2_7 -if $data2_6 != slave then +if $data2_6 != follower then goto show7 endi @@ -459,10 +459,10 @@ print dnode7 ==> $data2_7 if $data2_1 != offline then goto show9 endi -if $data2_5 != master then +if $data2_5 != leader then goto show9 endi -if $data2_6 != slave then +if $data2_6 != follower then goto show9 endi @@ -488,13 +488,13 @@ print dnode7 ==> $data2_7 if $data2_1 != null then goto show10 endi -if $data2_5 != master then +if $data2_5 != leader then goto show10 endi -if $data2_6 != slave then +if $data2_6 != follower then goto show10 endi -if $data2_7 != slave then +if $data2_7 != follower then goto show10 endi diff --git a/tests/script/unique/cluster/cache.sim b/tests/script/unique/cluster/cache.sim index 1b3771353f8ca411db1fc8ea62335c5ecc16bf45..f4da8380eb28789666d99f39501b66103df4d394 100644 --- a/tests/script/unique/cluster/cache.sim +++ b/tests/script/unique/cluster/cache.sim @@ -57,9 +57,9 @@ endi #sql create table sys.st as select avg(taosd), avg(system) from sys.cpu interval(30s) sql show log.vgroups -if $data05 != master then +if $data05 != leader then return -1 endi -if $data15 != master then +if $data15 != leader then return -1 endi diff --git a/tests/script/unique/cluster/flowctrl.sim b/tests/script/unique/cluster/flowctrl.sim index 700fa0a3f195c84ed6e7903fe572c81b20b4fd21..8e04767ffd04099e7dc3ae4355b3740921d81203 100644 --- a/tests/script/unique/cluster/flowctrl.sim +++ b/tests/script/unique/cluster/flowctrl.sim @@ -55,13 +55,13 @@ print mnode2Role $mnode2Role $mnode3Role = $data2_3 print mnode3Role $mnode3Role -if $mnode1Role != master then +if $mnode1Role != leader then goto show1 endi -if $mnode2Role != slave then +if $mnode2Role != follower then goto show1 endi -if $mnode3Role != slave then +if $mnode3Role != follower then goto show1 endi diff --git a/tests/script/unique/cluster/vgroup100.sim b/tests/script/unique/cluster/vgroup100.sim index 656ed2ec44ebbb2d666ed2618e15d5ae34a5e525..cfe27657985135eebd13d9f1bcf563b536131177 100644 --- a/tests/script/unique/cluster/vgroup100.sim +++ b/tests/script/unique/cluster/vgroup100.sim @@ -46,13 +46,13 @@ print $dnode1Role print $dnode2Role print $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto show2 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto show2 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto show2 endi @@ -109,13 +109,13 @@ sql show mnodes -x show7 $dnode1Role = $data2_1 $dnode2Role = $data2_2 $dnode3Role = $data2_3 -if $dnode1Role != master then +if $dnode1Role != leader then goto show7 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto show7 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto show7 endi diff --git a/tests/script/unique/clusterSimCase/cluster_main.sim b/tests/script/unique/clusterSimCase/cluster_main.sim index 274ce85974bb2238bae60e6ffa9723760ae1c394..2ec6ce9b55bec90924ce4ac721bf44501ae787e8 100644 --- a/tests/script/unique/clusterSimCase/cluster_main.sim +++ b/tests/script/unique/clusterSimCase/cluster_main.sim @@ -10,17 +10,17 @@ #taos> show vgroups; # vgId | tables | status | onlineVnodes | dnode | vstatus | dnode | vstatus | #====================================================================================================== -# 2 | 1024 | ready | 2 | 3 | master | 2 | slave | -# 3 | 1024 | ready | 2 | 3 | master | 2 | slave | -# 4 | 1024 | ready | 2 | 3 | master | 2 | slave | -# 5 | 718 | ready | 2 | 3 | master | 2 | slave | +# 2 | 1024 | ready | 2 | 3 | leader | 2 | follower | +# 3 | 1024 | ready | 2 | 3 | leader | 2 | follower | +# 4 | 1024 | ready | 2 | 3 | leader | 2 | follower | +# 5 | 718 | ready | 2 | 3 | leader | 2 | follower | #Query OK, 4 row(s) in set (0.002749s) # #taos> show mnodes # -> ; # id | end_point | role | create_time | #===================================================================================== -# 1 | ubuntu-OptiPlex-7060:7100 | master | 2020-07-22 06:25:31.677 | +# 1 | ubuntu-OptiPlex-7060:7100 | leader | 2020-07-22 06:25:31.677 | #Query OK, 1 row(s) in set (0.002126s) @@ -136,7 +136,7 @@ if $vg2Dnode3Status != offline then sleep 2000 goto wait_vgroup_chang_0 endi -if $vg2Dnode2Status != master then +if $vg2Dnode2Status != leader then sleep 2000 goto wait_vgroup_chang_0 endi @@ -165,11 +165,11 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $vg2Dnode3Status = $data5_2 $vg2Dnode2Status = $data7_2 -if $vg2Dnode3Status != slave then +if $vg2Dnode3Status != follower then sleep 2000 goto wait_vgroup_chang_1 endi -if $vg2Dnode2Status != master then +if $vg2Dnode2Status != leader then sleep 2000 goto wait_vgroup_chang_1 endi @@ -197,7 +197,7 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $vg2Dnode3Status = $data5_2 $vg2Dnode2Status = $data7_2 -if $vg2Dnode3Status != master then +if $vg2Dnode3Status != leader then sleep 2000 goto wait_vgroup_chang_2 endi @@ -230,11 +230,11 @@ print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $dat $vg2Dnode3Status = $data5_2 $vg2Dnode2Status = $data7_2 -if $vg2Dnode2Status != slave then +if $vg2Dnode2Status != follower then sleep 2000 goto wait_vgroup_chang_3 endi -if $vg2Dnode3Status != master then +if $vg2Dnode3Status != leader then sleep 2000 goto wait_vgroup_chang_3 endi diff --git a/tests/script/unique/db/commit.sim b/tests/script/unique/db/commit.sim index 661dd4505f704fff961739075247d4264d617f72..dec78c8e43cee9fda4328f59d0336502790b19f5 100644 --- a/tests/script/unique/db/commit.sim +++ b/tests/script/unique/db/commit.sim @@ -13,7 +13,7 @@ system sh/cfg.sh -n dnode1 -c mnodeEqualVnodeNum -v 4 system sh/cfg.sh -n dnode2 -c mnodeEqualVnodeNum -v 4 system sh/cfg.sh -n dnode3 -c mnodeEqualVnodeNum -v 4 -print ========= start dnode1 as master +print ========= start dnode1 as leader system sh/exec.sh -n dnode1 -s start sql connect sleep 2000 diff --git a/tests/script/unique/db/delete.sim b/tests/script/unique/db/delete.sim index c876f23de35f67b0cd2a6f0e428a825d98de7c27..b0ad52e494143a1a0218855c68ab473efde95086 100644 --- a/tests/script/unique/db/delete.sim +++ b/tests/script/unique/db/delete.sim @@ -84,7 +84,7 @@ step3: sql show mnodes print dnode1 role $data2_1 -if $data2_1 != master then +if $data2_1 != leader then goto step3 endi diff --git a/tests/script/unique/db/replica_add12.sim b/tests/script/unique/db/replica_add12.sim index d46187e4456acbd39c7b1f7689388af156d04f85..6cca6ce4cd5c64344d3d0115c6a10bdb1ac8e4a6 100644 --- a/tests/script/unique/db/replica_add12.sim +++ b/tests/script/unique/db/replica_add12.sim @@ -60,7 +60,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi if $data2_2 != null then diff --git a/tests/script/unique/db/replica_add13.sim b/tests/script/unique/db/replica_add13.sim index 13a5c9783228761c2b431f9bb1f571c29c05f080..6bc76615da0baa0072c60bab3db9a71a2e78bcff 100644 --- a/tests/script/unique/db/replica_add13.sim +++ b/tests/script/unique/db/replica_add13.sim @@ -66,7 +66,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/db/replica_add23.sim b/tests/script/unique/db/replica_add23.sim index ac0bd6d9d7b09065c832fb8ad0698b97a9f94853..ffc62abb8ea52cd8851f98efb9f063228875a4f9 100644 --- a/tests/script/unique/db/replica_add23.sim +++ b/tests/script/unique/db/replica_add23.sim @@ -67,7 +67,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/db/replica_part.sim b/tests/script/unique/db/replica_part.sim index 9880ec666c8543676c406c843d14235a09ae13ee..924d544c4299b67b0946ff34984a87f228212793 100644 --- a/tests/script/unique/db/replica_part.sim +++ b/tests/script/unique/db/replica_part.sim @@ -54,7 +54,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/db/replica_reduce21.sim b/tests/script/unique/db/replica_reduce21.sim index d3a76485f81616497a8c4859aafefda7ef371c01..0305f3ad09e1df41e27960f6d2fea7c6035636f1 100644 --- a/tests/script/unique/db/replica_reduce21.sim +++ b/tests/script/unique/db/replica_reduce21.sim @@ -47,7 +47,7 @@ endi sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/db/replica_reduce31.sim b/tests/script/unique/db/replica_reduce31.sim index f97af083fd199a4b71421d3c2d33f3b7961e8aa2..f7a745a3d5b02bb8f8d86344f244a01fdb416b21 100644 --- a/tests/script/unique/db/replica_reduce31.sim +++ b/tests/script/unique/db/replica_reduce31.sim @@ -60,7 +60,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/db/replica_reduce32.sim b/tests/script/unique/db/replica_reduce32.sim index ead265d5d54bd415d12147e5b61b04fcc5d7544f..730661ec02f3b488c26e07cfe4e6d534f0bef214 100644 --- a/tests/script/unique/db/replica_reduce32.sim +++ b/tests/script/unique/db/replica_reduce32.sim @@ -54,7 +54,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi if $data2_2 != null then diff --git a/tests/script/unique/dnode/alternativeRole.sim b/tests/script/unique/dnode/alternativeRole.sim index 7e647925d1d3d66d21f279ace852e3fc12496510..ce13a4a847ea6ad056b9d7bfeef8076ea5c5ef4e 100644 --- a/tests/script/unique/dnode/alternativeRole.sim +++ b/tests/script/unique/dnode/alternativeRole.sim @@ -66,13 +66,13 @@ sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 print dnode3 ==> $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi if $data2_2 != null then goto show2 endi -if $data2_3 != slave then +if $data2_3 != follower then goto show2 endi diff --git a/tests/script/unique/dnode/offline3.sim b/tests/script/unique/dnode/offline3.sim index 93c75e3b13333d55aea7cb2417413a14a1c13e62..de5cc946453c1d96e4a6867b0ffa5ffb673ca7c6 100644 --- a/tests/script/unique/dnode/offline3.sim +++ b/tests/script/unique/dnode/offline3.sim @@ -59,7 +59,7 @@ endi sql show mnodes print mnode1 $data2_1 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/http/admin.sim b/tests/script/unique/http/admin.sim index ae206744c4e93ab7cebd5f4db7d8d4b84ad5ebbb..39138d6db7ed5b5e9f0a17303692aee409afe6bc 100644 --- a/tests/script/unique/http/admin.sim +++ b/tests/script/unique/http/admin.sim @@ -178,7 +178,7 @@ endi print =============== step8 - monitor dbs #system_content curl -H 'Authorization: Taosd /KfeAzX/f9na8qdtNZmtONryp201ma04bEl8LcvLUd7a8qdtNZmtONryp201ma04' -d 'show dnodes;show mnodes;' 127.0.0.1:7111/admin/sqls #print 24-> $system_content -#if $system_content != @[{"status":"succ","head":["IP","created time","open vnodes","free vnodes","status","balance state"],"data":[["127.0.0.1","2018-09-04 #11:16:13.985",1,3,"ready","balanced"]],"rows":1},{"status":"succ","head":["IP","created time","status","role"],"data":[["127.0.0.1","2018-09-04 11:16:13.371","serving","master"]],"rows":1}]@ then +#if $system_content != @[{"status":"succ","head":["IP","created time","open vnodes","free vnodes","status","balance state"],"data":[["127.0.0.1","2018-09-04 #11:16:13.985",1,3,"ready","balanced"]],"rows":1},{"status":"succ","head":["IP","created time","status","role"],"data":[["127.0.0.1","2018-09-04 11:16:13.371","serving","leader"]],"rows":1}]@ then # return -1 # endi diff --git a/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeDir.sim b/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeDir.sim index e3623c7c629d671eedc7b6a416b9e77e6445c4ff..fbffc0a69b2e0e85dc70423833a5737e0b85e2a3 100644 --- a/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeDir.sim +++ b/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeDir.sim @@ -195,33 +195,33 @@ print $data0_2 $data1_2 $data2_2 $data3_2 $data4_2 $data5_2 $data6_2 $dat print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $data7_3 $data8_3 $data9_3 print $data0_4 $data1_4 $data2_4 $data3_4 $data4_4 $data5_4 $data6_4 $data7_4 $data8_4 $data9_4 -if $data5_4 != master then +if $data5_4 != leader then print $data5_4 sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data5_3 != slave then +if $data5_3 != follower then print $data5_2 sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data5_2 != master then +if $data5_2 != leader then print $data5_3 sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_4 != slave then +if $data7_4 != follower then print $data7_4 sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_3 != master then +if $data7_3 != leader then print $data7_3 sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_2 != slave then +if $data7_2 != follower then print $data7_2 sleep 2000 goto wait_dnode1_vgroup_slave diff --git a/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir.sim b/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir.sim index c88e26d7eb19a533be84f646321e103480b2d10a..b076c4c5010d1f53a994c11efb641eed89fbb830 100644 --- a/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir.sim +++ b/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir.sim @@ -197,28 +197,28 @@ print $data0_2 $data1_2 $data2_2 $data3_2 $data4_2 $data5_2 $data6_2 $dat print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $data7_3 $data8_3 $data9_3 print $data0_4 $data1_4 $data2_4 $data3_4 $data4_4 $data5_4 $data6_4 $data7_4 $data8_4 $data9_4 -if $data5_4 != master then +if $data5_4 != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data5_3 != slave then +if $data5_3 != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data5_2 != master then +if $data5_2 != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_4 != slave then +if $data7_4 != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_3 != master then +if $data7_3 != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_2 != slave then +if $data7_2 != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi diff --git a/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir_stopAll_starAll.sim b/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir_stopAll_starAll.sim index 69e83a2c0091394b2babf76a592ab80a95ae3e6a..9fe8e31db92fc024c3ab748a5b2aad481a38988e 100644 --- a/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir_stopAll_starAll.sim +++ b/tests/script/unique/migrate/mn2_vn2_repl2_rmMnodeVnodeDir_stopAll_starAll.sim @@ -169,28 +169,28 @@ $d1v2status = $data7_4 $d1v3status = $data7_2 $d1v4status = $data7_3 -if $d2v2status != master then +if $d2v2status != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $d2v3status != master then +if $d2v3status != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $d2v4status != master then +if $d2v4status != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $d1v2status != slave then +if $d1v2status != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $d1v3status != slave then +if $d1v3status != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $d1v4status != slave then +if $d1v4status != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi diff --git a/tests/script/unique/migrate/mn2_vn2_repl2_rmVnodeDir.sim b/tests/script/unique/migrate/mn2_vn2_repl2_rmVnodeDir.sim index ed3f9b8274c204727a08c163596316ed17808d6b..f665f551f71917c7b4328f122c2249db78594416 100644 --- a/tests/script/unique/migrate/mn2_vn2_repl2_rmVnodeDir.sim +++ b/tests/script/unique/migrate/mn2_vn2_repl2_rmVnodeDir.sim @@ -195,28 +195,28 @@ print $data0_2 $data1_2 $data2_2 $data3_2 $data4_2 $data5_2 $data6_2 $dat print $data0_3 $data1_3 $data2_3 $data3_3 $data4_3 $data5_3 $data6_3 $data7_3 $data8_3 $data9_3 print $data0_4 $data1_4 $data2_4 $data3_4 $data4_4 $data5_4 $data6_4 $data7_4 $data8_4 $data9_4 -if $data5_4 != master then +if $data5_4 != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data5_3 != slave then +if $data5_3 != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data5_2 != master then +if $data5_2 != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_4 != slave then +if $data7_4 != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_3 != master then +if $data7_3 != leader then sleep 2000 goto wait_dnode1_vgroup_slave endi -if $data7_2 != slave then +if $data7_2 != follower then sleep 2000 goto wait_dnode1_vgroup_slave endi diff --git a/tests/script/unique/mnode/mgmt20.sim b/tests/script/unique/mnode/mgmt20.sim index 8945cffab226ab5dc379057d55e562f5c3ed9cfa..710b3aa169b0cd4433b1d6e28f14bd2c140e5571 100644 --- a/tests/script/unique/mnode/mgmt20.sim +++ b/tests/script/unique/mnode/mgmt20.sim @@ -27,10 +27,10 @@ show2: sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show2 endi @@ -61,10 +61,10 @@ show4: sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show4 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show4 endi diff --git a/tests/script/unique/mnode/mgmt21.sim b/tests/script/unique/mnode/mgmt21.sim index 8409383309dbde5500b9719cd64fd74ca5e384b2..44000de86085166747908ae54771043c4db5f3ed 100644 --- a/tests/script/unique/mnode/mgmt21.sim +++ b/tests/script/unique/mnode/mgmt21.sim @@ -15,7 +15,7 @@ sql connect sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi @@ -33,10 +33,10 @@ show2: sql show mnodes -x show2 print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show2 endi diff --git a/tests/script/unique/mnode/mgmt22.sim b/tests/script/unique/mnode/mgmt22.sim index 399805312ba905d55bceffe011cfe074c831684e..415a40c21ce13dc108980364cb2978017193bbe9 100644 --- a/tests/script/unique/mnode/mgmt22.sim +++ b/tests/script/unique/mnode/mgmt22.sim @@ -14,7 +14,7 @@ sql connect sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi @@ -33,26 +33,26 @@ show2: sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show2 endi print ============== step3 sql_error drop dnode $hostname1 -x error1 -print should not drop master +print should not drop leader print ============== step4 system sh/exec.sh -n dnode1 -s stop -x SIGINT sleep 3000 sql_error show mnodes -print error of no master +print error of no leader print ============== step5 sql_error drop dnode $hostname1 -print error of no master +print error of no leader print ============== step6 system sh/exec.sh -n dnode1 -s start @@ -71,10 +71,10 @@ show6: sql show mnodes -x show6 print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show6 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show6 endi @@ -94,10 +94,10 @@ sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 print dnode3 ==> $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto show7 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show7 endi if $data3_3 != null then diff --git a/tests/script/unique/mnode/mgmt23.sim b/tests/script/unique/mnode/mgmt23.sim index 19c7b4ba762d4bf5a73c10c1afa39e927c7a1c91..1145c271883f62d67ac6e4f5968477eac820ac01 100644 --- a/tests/script/unique/mnode/mgmt23.sim +++ b/tests/script/unique/mnode/mgmt23.sim @@ -14,7 +14,7 @@ sql connect sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi @@ -33,10 +33,10 @@ show2: sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show2 endi @@ -53,10 +53,10 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi -if $dnode2Role != slave then +if $dnode2Role != follower then return -1 endi if $dnode3Role != null then @@ -82,13 +82,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step4 endi if $dnode2Role != null then goto step4 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step4 endi @@ -117,13 +117,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step5 endi if $dnode2Role != null then goto step5 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step5 endi diff --git a/tests/script/unique/mnode/mgmt24.sim b/tests/script/unique/mnode/mgmt24.sim index a7bcc59ac0bfa6163d1e2fddfd3a817b102bfa3c..c68a7236f9b6e517eaa2378338cf1c1cd64dd68c 100644 --- a/tests/script/unique/mnode/mgmt24.sim +++ b/tests/script/unique/mnode/mgmt24.sim @@ -14,7 +14,7 @@ sql connect sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi @@ -33,10 +33,10 @@ show2: sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show2 endi @@ -67,10 +67,10 @@ sql show mnodes -x step5 print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto step5 endi -if $data2_2 != slave then +if $data2_2 != follower then goto step5 endi diff --git a/tests/script/unique/mnode/mgmt25.sim b/tests/script/unique/mnode/mgmt25.sim index 9cca9c844806b138faf52186ffc3184d4876a1d6..f9564f4f1a28fbcfda0ef09d1d2bb07547faa62a 100644 --- a/tests/script/unique/mnode/mgmt25.sim +++ b/tests/script/unique/mnode/mgmt25.sim @@ -14,7 +14,7 @@ sql connect sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi @@ -33,10 +33,10 @@ show2: sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show2 endi @@ -53,10 +53,10 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi -if $dnode2Role != slave then +if $dnode2Role != follower then return -1 endi if $dnode3Role != null then @@ -75,13 +75,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi if $dnode2Role != null then return -1 endi -if $dnode3Role != slave then +if $dnode3Role != follower then return -1 endi diff --git a/tests/script/unique/mnode/mgmt26.sim b/tests/script/unique/mnode/mgmt26.sim index 2816845052e835cf11e0ec7d4ddc71cbdee0ada1..34bd3defba85b30a03f9c81bb99685237faef9c7 100644 --- a/tests/script/unique/mnode/mgmt26.sim +++ b/tests/script/unique/mnode/mgmt26.sim @@ -14,7 +14,7 @@ sql connect sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi @@ -33,10 +33,10 @@ show2: sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 -if $data2_1 != master then +if $data2_1 != leader then goto show2 endi -if $data2_2 != slave then +if $data2_2 != follower then goto show2 endi @@ -53,10 +53,10 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi -if $dnode2Role != slave then +if $dnode2Role != follower then return -1 endi if $dnode3Role != null then @@ -76,13 +76,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi if $dnode2Role != null then return -1 endi -if $dnode3Role != slave then +if $dnode3Role != follower then return -1 endi @@ -103,13 +103,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi if $dnode2Role != null then return -1 endi -if $dnode3Role != slave then +if $dnode3Role != follower then return -1 endi diff --git a/tests/script/unique/mnode/mgmt30.sim b/tests/script/unique/mnode/mgmt30.sim index d0858c0d6cdffa1cb1cd7f2ba570ae0521f412d5..3a6140539bfa260a577c5d6b2592fde894f5a1c7 100644 --- a/tests/script/unique/mnode/mgmt30.sim +++ b/tests/script/unique/mnode/mgmt30.sim @@ -19,7 +19,7 @@ sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 print dnode3 ==> $data3_3 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi if $data3_2 != null then @@ -53,13 +53,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step2 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step2 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step2 endi diff --git a/tests/script/unique/mnode/mgmt33.sim b/tests/script/unique/mnode/mgmt33.sim index ce7cdce35d8c0463564f46d26a0711d39340c8bf..ad05cd4f6be778f2f7a827d1f50089b5c5e67ddd 100644 --- a/tests/script/unique/mnode/mgmt33.sim +++ b/tests/script/unique/mnode/mgmt33.sim @@ -15,7 +15,7 @@ sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 print dnode3 ==> $data3_3 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi if $data3_2 != null then @@ -45,10 +45,10 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step2 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step2 endi if $dnode3Role != null then @@ -75,13 +75,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step3 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step3 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step3 endi @@ -104,13 +104,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step4 endi if $dnode2Role != null then goto step4 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step4 endi @@ -138,13 +138,13 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step5 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step5 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step5 endi @@ -169,10 +169,10 @@ print dnode3 ==> $dnode3Role if $dnode1Role != offline then goto step6 endi -#if $dnode2Role != master then +#if $dnode2Role != leader then # return -1 #endi -#if $dnode3Role != slave then +#if $dnode3Role != follower then # return -1 #endi @@ -197,10 +197,10 @@ print dnode3 ==> $dnode3Role if $dnode1Role != null then goto step7 endi -#if $dnode2Role != master then +#if $dnode2Role != leader then # return -1 #endi -#if $dnode3Role != slave then +#if $dnode3Role != follower then # return -1 #endi diff --git a/tests/script/unique/mnode/mgmt34.sim b/tests/script/unique/mnode/mgmt34.sim index d8a46b0955f59273279bbbc5c89c07c05db672d7..7f62b43fb8bcd8c4987ca99f78eec1d8d49a88ed 100644 --- a/tests/script/unique/mnode/mgmt34.sim +++ b/tests/script/unique/mnode/mgmt34.sim @@ -18,7 +18,7 @@ sql show mnodes print dnode1 ==> $data2_1 print dnode2 ==> $data2_2 print dnode3 ==> $data3_3 -if $data2_1 != master then +if $data2_1 != leader then return -1 endi if $data3_2 != null then @@ -49,10 +49,10 @@ print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step2 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step2 endi if $dnode3Role != null then @@ -84,13 +84,13 @@ print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step3 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step3 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step3 endi if $dnode4Role != null then @@ -119,13 +119,13 @@ print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step4 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step4 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step4 endi if $dnode4Role != null then @@ -152,16 +152,16 @@ print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step5 endi if $dnode2Role != null then goto step5 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step5 endi -if $dnode4Role != slave then +if $dnode4Role != follower then goto step5 endi @@ -190,16 +190,16 @@ print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role print dnode4 ==> $dnode4Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step6 endi if $dnode2Role != null then goto step6 endi -if $dnode3Role != slave then +if $dnode3Role != follower then goto step6 endi -if $dnode4Role != slave then +if $dnode4Role != follower then goto step6 endi @@ -249,13 +249,13 @@ print dnode4 ==> $dnode4Role if $dnode1Role != null then goto step8 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step8 endi -#if $dnode3Role != master then +#if $dnode3Role != leader then # return -1 #endi -#if $dnode4Role != slave then +#if $dnode4Role != follower then # return -1 #endi diff --git a/tests/script/unique/mnode/mgmtr2.sim b/tests/script/unique/mnode/mgmtr2.sim index 5afb41905846bff3ce9894e928245a7d34078354..fee2e405a283736272892367aae93582cc98f3ba 100644 --- a/tests/script/unique/mnode/mgmtr2.sim +++ b/tests/script/unique/mnode/mgmtr2.sim @@ -20,7 +20,7 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then return -1 endi if $dnode2Role != null then @@ -72,10 +72,10 @@ print dnode1 ==> $dnode1Role print dnode2 ==> $dnode2Role print dnode3 ==> $dnode3Role -if $dnode1Role != master then +if $dnode1Role != leader then goto step4 endi -if $dnode2Role != slave then +if $dnode2Role != follower then goto step4 endi if $dnode3Role != null then diff --git a/tests/script/unique/vnode/many.sim b/tests/script/unique/vnode/many.sim index a9298b1cf275c24ab6ebe7fea9387a51d6d044ba..24e2cd60c7458d3bab027a80632bd5cddc5b7eba 100644 --- a/tests/script/unique/vnode/many.sim +++ b/tests/script/unique/vnode/many.sim @@ -51,7 +51,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/vnode/replica2_repeat.sim b/tests/script/unique/vnode/replica2_repeat.sim index ac68d591648b2dd66f3fdda8c70b0af40c814459..9845ef2d199ddcfe71ca664033bbf16ea84c24ec 100644 --- a/tests/script/unique/vnode/replica2_repeat.sim +++ b/tests/script/unique/vnode/replica2_repeat.sim @@ -52,7 +52,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi diff --git a/tests/script/unique/vnode/replica3_basic.sim b/tests/script/unique/vnode/replica3_basic.sim index 0ff42b523b8982c85bd84bb251715585a66137fc..edb70b7d4cbaf53d85cd54b9282bda64562cc52d 100644 --- a/tests/script/unique/vnode/replica3_basic.sim +++ b/tests/script/unique/vnode/replica3_basic.sim @@ -44,13 +44,13 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi -if $data2_2 != slave then +if $data2_2 != follower then goto step1 endi -if $data2_3 != slave then +if $data2_3 != follower then goto step1 endi diff --git a/tests/script/unique/vnode/replica3_repeat.sim b/tests/script/unique/vnode/replica3_repeat.sim index 636bc64f89948a8bd4ec0d3dc9dc2a1b10f50e00..cde0c512a5c2d719171635a29a1fba94d1611ab9 100644 --- a/tests/script/unique/vnode/replica3_repeat.sim +++ b/tests/script/unique/vnode/replica3_repeat.sim @@ -59,7 +59,7 @@ sql show mnodes print mnode1 $data2_1 print mnode1 $data2_2 print mnode1 $data2_3 -if $data2_1 != master then +if $data2_1 != leader then goto step1 endi