List:Commits« Previous MessageNext Message »
From:jmiller Date:January 9 2008 6:01pm
Subject:bk commit into 5.1 tree (jmiller:1.2654)
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of jmiller.  When jmiller does a push these changes
will be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet@stripped, 2008-01-09 19:01:31+01:00, jmiller@stripped +1 -0
  NdbRepStress.cpp:
    More code improvments

  storage/ndb/test/ndbapi/acrt/NdbRepStress.cpp@stripped, 2008-01-09 19:01:18+01:00, jmiller@stripped +4 -6
    More code improvments

diff -Nrup a/storage/ndb/test/ndbapi/acrt/NdbRepStress.cpp b/storage/ndb/test/ndbapi/acrt/NdbRepStress.cpp
--- a/storage/ndb/test/ndbapi/acrt/NdbRepStress.cpp	2008-01-09 18:54:05 +01:00
+++ b/storage/ndb/test/ndbapi/acrt/NdbRepStress.cpp	2008-01-09 19:01:18 +01:00
@@ -26,8 +26,6 @@ Will include restart testing in future p
 #include <NdbRestarts.hpp>
 */
 
-static  int t1_records = 50000;
-
 /**** TOOL SECTION ****/
 
 static uint
@@ -360,7 +358,7 @@ createTable_rep1(NDBT_Context* ctx, NDBT
   ctx->setProperty("TABLES",table.c_str());
   HugoTransactions hugoTrans(*ctx->getTab());
 
-  if (hugoTrans.loadTable(GETNDB(step), t1_records, 1, true, 0) != NDBT_OK)
+  if (hugoTrans.loadTable(GETNDB(step), ctx->getNumRecords(), 1, true, 0) != NDBT_OK)
   {
     g_err << "Create Table -> Load failed!" << endl;
     return NDBT_FAILED;
@@ -383,12 +381,12 @@ stressNDB_rep1(NDBT_Context* ctx, NDBT_S
   HugoTransactions hugoTrans(* table);
   while(!ctx->isTestStopped())
   {
-    if (hugoTrans.pkUpdateRecords(GETNDB(step), t1_records, 1, 30) != 0)
+    if (hugoTrans.pkUpdateRecords(GETNDB(step), ctx->getNumRecords(), 1, 30) != 0)
     {
       g_err << "pkUpdate Failed!" << endl;
       return NDBT_FAILED;
     }
-    if (hugoTrans.scanUpdateRecords(GETNDB(step), t1_records, 1, 30) != 0)
+    if (hugoTrans.scanUpdateRecords(GETNDB(step), ctx->getNumRecords(), 1, 30) != 0)
     {
       g_err << "scanUpdate Failed!" << endl;
       return NDBT_FAILED;
@@ -415,7 +413,7 @@ stressSQL_rep1(NDBT_Context* ctx, NDBT_S
 
   for (int j= 0; loops == 0 || j < loops; j++)
   {
-    record = urandom(t1_records);
+    record = urandom(ctx->getNumRecords());
     sqlStm.assfmt("UPDATE TEST_DB.rep1 SET c2 = 33.3221 where c1 =  %u", record);
     if(master.doQuery(sqlStm.c_str()))
     {
Thread
bk commit into 5.1 tree (jmiller:1.2654)jmiller9 Jan