mirror of
https://github.com/MariaDB/server.git
synced 2025-01-22 14:54:20 +01:00
ndb - replication bug fix
Fix gci reply on TC_COMMITREQ (prefered way of mysqld) ndb/include/kernel/signaldata/TcCommit.hpp: Fix gci reply on TC_COMMITREQ (prefered way of mysqld) ndb/src/kernel/blocks/dbtc/DbtcMain.cpp: Fix gci reply on TC_COMMITREQ (prefered way of mysqld) ndb/src/ndbapi/NdbTransaction.cpp: Fix gci reply on TC_COMMITREQ (prefered way of mysqld)
This commit is contained in:
parent
6f7ead2c77
commit
d89676d8d7
3 changed files with 9 additions and 5 deletions
|
@ -36,7 +36,7 @@ class TcCommitConf {
|
||||||
friend class NdbTransaction;
|
friend class NdbTransaction;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
STATIC_CONST( SignalLength = 3 );
|
STATIC_CONST( SignalLength = 4 );
|
||||||
private:
|
private:
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -49,6 +49,7 @@ private:
|
||||||
|
|
||||||
Uint32 transId1;
|
Uint32 transId1;
|
||||||
Uint32 transId2;
|
Uint32 transId2;
|
||||||
|
Uint32 gci;
|
||||||
};
|
};
|
||||||
|
|
||||||
class TcCommitRef {
|
class TcCommitRef {
|
||||||
|
|
|
@ -4688,8 +4688,9 @@ void Dbtc::sendApiCommit(Signal* signal)
|
||||||
}
|
}
|
||||||
commitConf->transId1 = regApiPtr->transid[0];
|
commitConf->transId1 = regApiPtr->transid[0];
|
||||||
commitConf->transId2 = regApiPtr->transid[1];
|
commitConf->transId2 = regApiPtr->transid[1];
|
||||||
|
commitConf->gci = regApiPtr->globalcheckpointid;
|
||||||
sendSignal(regApiPtr->ndbapiBlockref, GSN_TC_COMMITCONF, signal, 3, JBB);
|
sendSignal(regApiPtr->ndbapiBlockref, GSN_TC_COMMITCONF, signal,
|
||||||
|
TcCommitConf::SignalLength, JBB);
|
||||||
} else if (regApiPtr->returnsignal == RS_NO_RETURN) {
|
} else if (regApiPtr->returnsignal == RS_NO_RETURN) {
|
||||||
jam();
|
jam();
|
||||||
} else {
|
} else {
|
||||||
|
@ -5382,8 +5383,9 @@ void Dbtc::execTC_COMMITREQ(Signal* signal)
|
||||||
commitConf->apiConnectPtr = apiConnectPtr;
|
commitConf->apiConnectPtr = apiConnectPtr;
|
||||||
commitConf->transId1 = transId1;
|
commitConf->transId1 = transId1;
|
||||||
commitConf->transId2 = transId2;
|
commitConf->transId2 = transId2;
|
||||||
|
commitConf->gci = 0;
|
||||||
sendSignal(apiBlockRef, GSN_TC_COMMITCONF, signal, 3, JBB);
|
sendSignal(apiBlockRef, GSN_TC_COMMITCONF, signal,
|
||||||
|
TcCommitConf::SignalLength, JBB);
|
||||||
|
|
||||||
regApiPtr->returnsignal = RS_NO_RETURN;
|
regApiPtr->returnsignal = RS_NO_RETURN;
|
||||||
releaseAbortResources(signal);
|
releaseAbortResources(signal);
|
||||||
|
|
|
@ -1490,6 +1490,7 @@ NdbTransaction::receiveTC_COMMITCONF(const TcCommitConf * commitConf)
|
||||||
if(checkState_TransId(&commitConf->transId1)){
|
if(checkState_TransId(&commitConf->transId1)){
|
||||||
theCommitStatus = Committed;
|
theCommitStatus = Committed;
|
||||||
theCompletionStatus = CompletedSuccess;
|
theCompletionStatus = CompletedSuccess;
|
||||||
|
theGlobalCheckpointId = commitConf->gci;
|
||||||
return 0;
|
return 0;
|
||||||
} else {
|
} else {
|
||||||
#ifdef NDB_NO_DROPPED_SIGNAL
|
#ifdef NDB_NO_DROPPED_SIGNAL
|
||||||
|
|
Loading…
Add table
Reference in a new issue