summaryrefslogtreecommitdiff
path: root/storage/ndb/test/ndbapi
diff options
context:
space:
mode:
authorunknown <jonas@perch.ndb.mysql.com>2007-11-19 10:47:26 +0100
committerunknown <jonas@perch.ndb.mysql.com>2007-11-19 10:47:26 +0100
commit7d50a31b72be061ea6b9200b8118b8d01e60cf9c (patch)
treefa066994604bd43cf0bd9428c3aeb87d085b56c6 /storage/ndb/test/ndbapi
parent79f8eeed86e81245a6c0b9059e3dc0363895085c (diff)
downloadmariadb-git-7d50a31b72be061ea6b9200b8118b8d01e60cf9c.tar.gz
ndb - bug#22696
Fix handling of multiple redo phases - set correct state - handle 4 phases, by moving START_FRAGCONF to end of phase instead of beginning... storage/ndb/src/kernel/blocks/dblqh/Dblqh.hpp: remove unused state ACTIVE_REMOVE_AFTER remove unused variable nextLcp remove unused methods (BUILD_INDX) add counter of outstanding GSN_EXEC_FRAGREQ remove c_redo_complete_fragments cause it fits badly with functional multi-redo-phases storage/ndb/src/kernel/blocks/dblqh/DblqhInit.cpp: remove unused stuff storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp: 1) set correct state before starting next non-empty REDO phase 2) move GSN_START_FRAGCONF to execFRAGCONF instead of when sending GSN_EXEC_FRAGREQ or fragments with 4 redo-phases would never be complete... storage/ndb/test/ndbapi/testSystemRestart.cpp: testcase storage/ndb/test/run-test/daily-basic-tests.txt: testcase
Diffstat (limited to 'storage/ndb/test/ndbapi')
-rw-r--r--storage/ndb/test/ndbapi/testSystemRestart.cpp41
1 files changed, 39 insertions, 2 deletions
diff --git a/storage/ndb/test/ndbapi/testSystemRestart.cpp b/storage/ndb/test/ndbapi/testSystemRestart.cpp
index 89580c0cef8..0f9100f67fa 100644
--- a/storage/ndb/test/ndbapi/testSystemRestart.cpp
+++ b/storage/ndb/test/ndbapi/testSystemRestart.cpp
@@ -1501,6 +1501,38 @@ int runSR_DD_2(NDBT_Context* ctx, NDBT_Step* step)
return result;
}
+int runBug22696(NDBT_Context* ctx, NDBT_Step* step)
+{
+ Ndb* pNdb = GETNDB(step);
+ int result = NDBT_OK;
+ Uint32 loops = ctx->getNumLoops();
+ Uint32 rows = ctx->getNumRecords();
+ NdbRestarter restarter;
+ HugoTransactions hugoTrans(*ctx->getTab());
+
+ Uint32 i = 0;
+ while(i<=loops && result != NDBT_FAILED)
+ {
+ for (Uint32 j = 0; j<10 && result != NDBT_FAILED; j++)
+ CHECK(hugoTrans.scanUpdateRecords(pNdb, rows) == 0);
+
+ CHECK(restarter.restartAll(false, true, i > 0 ? true : false) == 0);
+ CHECK(restarter.waitClusterNoStart() == 0);
+ CHECK(restarter.insertErrorInAllNodes(7072) == 0);
+ CHECK(restarter.startAll() == 0);
+ CHECK(restarter.waitClusterStarted() == 0);
+
+ i++;
+ if (i < loops)
+ {
+ NdbSleep_SecSleep(5); // Wait for a few gcp
+ }
+ }
+
+ ctx->stopTest();
+ return result;
+}
+
int
runBug27434(NDBT_Context* ctx, NDBT_Step* step)
{
@@ -1813,8 +1845,13 @@ TESTCASE("Bug28770",
STEP(runBug28770);
FINALIZER(runClearTable);
}
-
-
+TESTCASE("Bug22696", "")
+{
+ INITIALIZER(runWaitStarted);
+ INITIALIZER(runLoadTable);
+ INITIALIZER(runBug22696);
+ FINALIZER(runClearTable);
+}
NDBT_TESTSUITE_END(testSystemRestart);
int main(int argc, const char** argv){