|
|||||||||||
|
bk commit into 5.1 tree (jonas:1.2511) BUG#30975
From: <jonas(at)mysql.com>
Date: Sat Sep 29 2007 - 05:10:17 EDT
ChangeSet@1.2511, 2007-09-29 11:10:12+02:00, jonas@perch.ndb.mysql.com +2 -0
ndb - bug#30975
storage/ndb/test/ndbapi/testSystemRestart.cpp@1.15, 2007-09-29 11:10:09+02:00, jonas@perch.ndb.mysql.com +109 -21 add more tests... storage/ndb/test/run-test/daily-basic-tests.txt@1.80, 2007-09-29 11:10:09+02:00, jonas@perch.ndb.mysql.com +32 -0 add more tests # This is a BitKeeper patch. What follows are the unified diffs for the # set of deltas contained in the patch. The rest of the patch, the part # that BitKeeper cares about, is below these diffs. # User: jonas # Host: perch.ndb.mysql.com # Root: /home/jonas/src/51-telco-gca --- 1.79/storage/ndb/test/run-test/daily-basic-tests.txt 2007-09-29 11:10:17 +02:00@@ -876,29 +876,61 @@
max-time: 1500
max-time: 1500
max-time: 1500
max-time: 1500
max-time: 1500
max-time: 1500
max-time: 1500
+int
NdbRestarter restarter;
Uint32 i = 1;
ndbout << "Loading records..." << startFrom << endl;
CHECK(hugoTrans.loadTable(pNdb, startFrom) == 0);
- ndbout << "Making " << nodeId << " crash" << endl;
- int kill[] = { 9999, 1000, 3000 };
- CHECK(restarter.dumpStateOneNode(nodeId, val, 2) == 0);
- CHECK(restarter.dumpStateOneNode(nodeId, kill, 3) == 0);
-
+ if (!all) + { + ndbout << "Making " << nodeId << " crash" << endl; + int kill[] = { 9999, 1000, 3000 }; + CHECK(restarter.dumpStateOneNode(nodeId, val, 2) == 0); + CHECK(restarter.dumpStateOneNode(nodeId, kill, 3) == 0); + } + else + { + ndbout << "Crashing cluster" << endl; + ctx->setProperty("StopAbort", 1000 + rand() % (3000 - 1000)); + }
Uint64 end = NdbTick_CurrentMillisecond() + 4000;
Uint32 row = startFrom;
do {
@@ -1268,11 +1300,17 @@
row += 1000;
} while (NdbTick_CurrentMillisecond() < end);
- ndbout << "Waiting for " << nodeId << " to restart" << endl;
- CHECK(restarter.waitNodesNoStart(&nodeId, 1) == 0);
-
- ndbout << "Restarting cluster" << endl; - CHECK(restarter.restartAll(false, true, true) == 0); + if (!all) + { + ndbout << "Waiting for " << nodeId << " to restart" << endl; + CHECK(restarter.waitNodesNoStart(&nodeId, 1) == 0); + ndbout << "Restarting cluster" << endl; + CHECK(restarter.restartAll(false, true, true) == 0); + } + else + { + ndbout << "Waiting for cluster to restart" << endl; + }
CHECK(restarter.waitClusterNoStart() == 0);
CHECK(restarter.startAll() == 0);
CHECK(restarter.waitClusterStarted() == 0);
@@ -1297,7 +1335,7 @@
}
ndbout << "runSR_DD_1 finished" << endl;
-
return result;
@@ -1311,6 +1349,7 @@
NdbRestarter restarter;
Uint32 i = 1;
int nodeId = restarter.getDbNodeId(rand() % restarter.getNumDbNodes());
- ndbout << "Making " << nodeId << " crash" << endl;
- int kill[] = { 9999, 3000, 10000 };
- CHECK(restarter.dumpStateOneNode(nodeId, val, 2) == 0);
- CHECK(restarter.dumpStateOneNode(nodeId, kill, 3) == 0);
+ if (!all) + { + ndbout << "Making " << nodeId << " crash" << endl; + int kill[] = { 9999, 3000, 10000 }; + CHECK(restarter.dumpStateOneNode(nodeId, val, 2) == 0); + CHECK(restarter.dumpStateOneNode(nodeId, kill, 3) == 0); + } + else + { + ndbout << "Crashing cluster" << endl; + ctx->setProperty("StopAbort", 1000 + rand() % (3000 - 1000)); + }
Uint64 end = NdbTick_CurrentMillisecond() + 11000;
Uint32 row = startFrom;
@@ -1346,11 +1393,18 @@
break;
} while (NdbTick_CurrentMillisecond() < end);
- ndbout << "Waiting for " << nodeId << " to restart" << endl;
- CHECK(restarter.waitNodesNoStart(&nodeId, 1) == 0);
-
- ndbout << "Restarting cluster" << endl; - CHECK(restarter.restartAll(false, true, true) == 0); + if (!all) + { + ndbout << "Waiting for " << nodeId << " to restart" << endl; + CHECK(restarter.waitNodesNoStart(&nodeId, 1) == 0); + ndbout << "Restarting cluster" << endl; + CHECK(restarter.restartAll(false, true, true) == 0); + } + else + { + ndbout << "Waiting for cluster to restart" << endl; + } +
CHECK(restarter.waitClusterNoStart() == 0);
CHECK(restarter.startAll() == 0);
CHECK(restarter.waitClusterStarted() == 0);
@@ -1369,7 +1423,7 @@
}
ndbout << "runSR_DD_2 finished" << endl;
-
return result;
@@ -1555,12 +1609,29 @@
INITIALIZER(runWaitStarted);
TC_PROPERTY("LCP", 1);
INITIALIZER(runWaitStarted);
-- MySQL Code Commits Mailing List For list archives: http://lists.mysql.com/commits To unsubscribe: http://lists.mysql.com/commits?unsub=lists@pantek.comReceived on Sat Sep 29 05:11:16 2007 This archive was generated by hypermail 2.1.8 : Sun Oct 07 2007 - 09:45:05 EDT |
||||||||||
|
|||||||||||