List:Commits« Previous MessageNext Message »
From:Jonas Oreland Date:November 9 2009 1:23pm
Subject:bzr commit into mysql-5.1-telco-6.3 branch (jonas:3162) Bug#48564
View as plain text  
#At file:///home/jonas/src/telco-6.3/ based on revid:magnus.blaudd@stripped

 3162 Jonas Oreland	2009-11-09
      ndb - bug#48564 - add extra reserved scan record for LCP, and modify reservation code slightly

    modified:
      storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp
      storage/ndb/src/kernel/vm/Configuration.cpp
      storage/ndb/src/ndbapi/ndberror.c
=== modified file 'storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp'
--- a/storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp	2009-11-02 17:09:12 +0000
+++ b/storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp	2009-11-09 13:23:49 +0000
@@ -8752,10 +8752,23 @@ void Dblqh::execSCAN_FRAGREQ(Signal* sig
   }//if
   
   // 1 scan record is reserved for node recovery
-  if (cscanNoFreeRec < 2) {
-    jam();
-    errorCode = ScanFragRef::ZNO_FREE_SCANREC_ERROR;
-    goto error_handler;
+  // and one for LCP
+  {
+    Uint32 limit = 2;
+    if (ScanFragReq::getLcpScanFlag(reqinfo))
+    {
+      jam();
+      /**
+       * This code depends on the fact that LCP only scans one fragment at
+       *   at a time
+       */
+      limit = 1;
+    }
+    if (cscanNoFreeRec < limit) {
+      jam();
+      errorCode = ScanFragRef::ZNO_FREE_SCANREC_ERROR;
+      goto error_handler;
+    }
   }
 
   // XXX adjust cmaxAccOps for range scans and remove this comment

=== modified file 'storage/ndb/src/kernel/vm/Configuration.cpp'
--- a/storage/ndb/src/kernel/vm/Configuration.cpp	2009-05-27 12:11:46 +0000
+++ b/storage/ndb/src/kernel/vm/Configuration.cpp	2009-11-09 13:23:49 +0000
@@ -817,7 +817,9 @@ Configuration::calcSizeAlt(ConfigValues 
 
 
   if (noOfLocalScanRecords == 0) {
-    noOfLocalScanRecords = (noOfDBNodes * noOfScanRecords) + 1;
+    noOfLocalScanRecords = (noOfDBNodes * noOfScanRecords) + 
+      1 /* NR */ + 
+      1 /* LCP */; 
   }
   if (noOfLocalOperations == 0) {
     noOfLocalOperations= (11 * noOfOperations) / 10;

=== modified file 'storage/ndb/src/ndbapi/ndberror.c'
--- a/storage/ndb/src/ndbapi/ndberror.c	2009-10-01 22:29:59 +0000
+++ b/storage/ndb/src/ndbapi/ndberror.c	2009-11-09 13:23:49 +0000
@@ -179,6 +179,7 @@ ErrorBundle ErrorCodes[] = {
   { 419,  DMEC, TR, "419" },
   { 245,  DMEC, TR, "Too many active scans" },
   { 488,  DMEC, TR, "Too many active scans" },
+  { 489,  DMEC, TR, "Too many active scans" },
   { 490,  DMEC, TR, "Too many active scans" },
   { 805,  DMEC, TR, "Out of attrinfo records in tuple manager" },
   { 830,  DMEC, TR, "Out of add fragment operation records" },


Attachment: [text/bzr-bundle] bzr/jonas@mysql.com-20091109132349-2khtzhbi4x6ihe8z.bundle
Thread
bzr commit into mysql-5.1-telco-6.3 branch (jonas:3162) Bug#48564Jonas Oreland9 Nov