ndb - replication

  Make sure that SUB_GCP_COMPLETE_ACK is sent uncond, failure to do so can lead to problems...
parent 4dd67338
...@@ -385,16 +385,23 @@ void AsyncFile::openReq(Request* request) ...@@ -385,16 +385,23 @@ void AsyncFile::openReq(Request* request)
} }
new_flags |= O_CREAT; new_flags |= O_CREAT;
} }
no_odirect: no_odirect:
if (-1 == (theFd = ::open(theFileName.c_str(), new_flags, mode))) if (-1 == (theFd = ::open(theFileName.c_str(), new_flags, mode)))
{ {
PRINT_ERRORANDFLAGS(new_flags); PRINT_ERRORANDFLAGS(new_flags);
if ((errno == ENOENT ) && (new_flags & O_CREAT)) if ((errno == ENOENT) && (new_flags & O_CREAT))
{ {
createDirectories(); createDirectories();
if (-1 == (theFd = ::open(theFileName.c_str(), new_flags, mode))) if (-1 == (theFd = ::open(theFileName.c_str(), new_flags, mode)))
{ {
#ifdef O_DIRECT
if (new_flags & O_DIRECT)
{
new_flags &= ~O_DIRECT;
goto no_odirect;
}
#endif
PRINT_ERRORANDFLAGS(new_flags); PRINT_ERRORANDFLAGS(new_flags);
request->error = errno; request->error = errno;
return; return;
......
...@@ -343,7 +343,7 @@ execute(void * callbackObj, SignalHeader * const header, ...@@ -343,7 +343,7 @@ execute(void * callbackObj, SignalHeader * const header,
Uint32 aNodeId= refToNode(ref); Uint32 aNodeId= refToNode(ref);
tSignal.theReceiversBlockNumber= refToBlock(ref); tSignal.theReceiversBlockNumber= refToBlock(ref);
tSignal.theVerId_signalNumber= GSN_SUB_GCP_COMPLETE_ACK; tSignal.theVerId_signalNumber= GSN_SUB_GCP_COMPLETE_ACK;
theFacade->sendSignal(&tSignal, aNodeId); theFacade->sendSignalUnCond(&tSignal, aNodeId);
} }
break; break;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment