List:Commits« Previous MessageNext Message »
From:Ole John Aske Date:November 16 2011 7:34am
Subject:bzr push into mysql-5.1-telco-7.0-spj-scan-vs-scan branch
(ole.john.aske:3583 to 3584)
View as plain text  
 3584 Ole John Aske	2011-11-16 [merge]
      Merge mysql-5.1-telco-7.0 -> mysql-5.1-telco-7.0-spj-scan-scan

    modified:
      storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp
 3583 Ole John Aske	2011-11-15
      Changed ndb_join_pushdown.test into an included file.
      Added the new test ndb_join_pushdown_default.test which include the a above
      file and run it with default set of switches.

    added:
      mysql-test/suite/ndb/t/ndb_join_pushdown_default.test
    renamed:
      mysql-test/suite/ndb/r/ndb_join_pushdown.result => mysql-test/suite/ndb/r/ndb_join_pushdown_default.result
      mysql-test/suite/ndb/t/ndb_join_pushdown.test => mysql-test/suite/ndb/t/ndb_join_pushdown.inc
    modified:
      mysql-test/suite/ndb/t/ndb_join_pushdown.inc
=== modified file 'storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp'
--- a/storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp	2011-11-14 14:25:20 +0000
+++ b/storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp	2011-11-16 07:33:31 +0000
@@ -1221,29 +1221,35 @@ void Dblqh::execREAD_CONFIG_REQ(Signal* 
   ndbrequire(p != 0);
 
   clogPartFileSize = 4;
+
+  Uint32 nodeLogParts = 4;
   ndb_mgm_get_int_parameter(p, CFG_DB_NO_REDOLOG_PARTS,
-                            &clogPartFileSize);
-  globalData.ndbLogParts = clogPartFileSize;
-  ndbrequire(clogPartFileSize <= NDB_MAX_LOG_PARTS);
+                            &nodeLogParts);
+  globalData.ndbLogParts = nodeLogParts;
+  ndbrequire(nodeLogParts <= NDB_MAX_LOG_PARTS);
+  {
+    NdbLogPartInfo lpinfo(instance());
+    clogPartFileSize = lpinfo.partCount; // How many are this instance responsible for...
+  }
 
-  if (globalData.ndbMtLqhWorkers > clogPartFileSize)
+  if (globalData.ndbMtLqhWorkers > nodeLogParts)
   {
     char buf[255];
     BaseString::snprintf(buf, sizeof(buf),
       "Trying to start %d LQH workers with only %d log parts, try initial"
       " node restart to be able to use more LQH workers.",
-      globalData.ndbMtLqhWorkers, clogPartFileSize);
+      globalData.ndbMtLqhWorkers, nodeLogParts);
     progError(__LINE__, NDBD_EXIT_INVALID_CONFIG, buf);
   }
-  if (clogPartFileSize != 4 &&
-      clogPartFileSize != 8 &&
-      clogPartFileSize != 16)
+  if (nodeLogParts != 4 &&
+      nodeLogParts != 8 &&
+      nodeLogParts != 16)
   {
     char buf[255];
     BaseString::snprintf(buf, sizeof(buf),
       "Trying to start with %d log parts, number of log parts can"
       " only be set to 4, 8 or 16.",
-      clogPartFileSize);
+      nodeLogParts);
     progError(__LINE__, NDBD_EXIT_INVALID_CONFIG, buf);
   }
 
@@ -15728,7 +15734,7 @@ void Dblqh::initWriteEndLab(Signal* sign
 /* Set number of log parts used to ensure we use correct number of log parts */
 /* at system restart. Was previously hardcoded to 4.                         */
 /*---------------------------------------------------------------------------*/
-    logPagePtr.p->logPageWord[ZPOS_NO_LOG_PARTS]= clogPartFileSize;
+    logPagePtr.p->logPageWord[ZPOS_NO_LOG_PARTS]= globalData.ndbLogParts;
     logPagePtr.p->logPageWord[ZPOS_LOG_LAP] = 1;
     logPagePtr.p->logPageWord[ZPOS_MAX_GCI_STARTED] = 0;
     logPagePtr.p->logPageWord[ZPOS_MAX_GCI_COMPLETED] = 0;
@@ -16474,13 +16480,13 @@ void Dblqh::readSrFrontpageLab(Signal* s
       globalData.ndbMtLqhWorkers, num_parts_used);
     progError(__LINE__, NDBD_EXIT_INVALID_CONFIG, buf);
   }
-  if (num_parts_used != clogPartFileSize)
+  if (num_parts_used != globalData.ndbLogParts)
   {
     char buf[255];
     BaseString::snprintf(buf, sizeof(buf),
       "Can only change NoOfLogParts through initial node restart, old"
       " value of NoOfLogParts = %d, tried using %d",
-      num_parts_used, clogPartFileSize);
+      num_parts_used, globalData.ndbLogParts);
     progError(__LINE__, NDBD_EXIT_INVALID_CONFIG, buf);
   }
 

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-5.1-telco-7.0-spj-scan-vs-scan branch(ole.john.aske:3583 to 3584) Ole John Aske16 Nov