forked from huawei/openGauss-server
!156 Fix MOT replay in async commit mode
Merge pull request !156 from Vinoth/master
This commit is contained in:
commit
748be10fae
|
|
@ -13,7 +13,7 @@
|
|||
# you need to reload the server.
|
||||
#
|
||||
# This file is read ONLY on server startup. If you edit the file on a running system,
|
||||
# you have reload the server for the changes to take effect.
|
||||
# you have to reload the server for the changes to take effect.
|
||||
#
|
||||
# Memory units: KB = kilobytes
|
||||
# MB = megabytes
|
||||
|
|
|
|||
|
|
@ -74,6 +74,7 @@ RedoLogBuffer* AsyncRedoLogHandler::CreateBuffer()
|
|||
|
||||
void AsyncRedoLogHandler::DestroyBuffer(RedoLogBuffer* buffer)
|
||||
{
|
||||
buffer->Reset();
|
||||
m_bufferPool.Free(buffer);
|
||||
}
|
||||
|
||||
|
|
@ -131,6 +132,7 @@ bool AsyncRedoLogHandler::TrySwitchBuffers(int index)
|
|||
void AsyncRedoLogHandler::FreeBuffers(RedoLogBufferArray& bufferArray)
|
||||
{
|
||||
for (uint32_t i = 0; i < bufferArray.Size(); i++) {
|
||||
bufferArray[i]->Reset();
|
||||
m_bufferPool.Free(bufferArray[i]);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -56,6 +56,7 @@ bool RedoLog::Init()
|
|||
}
|
||||
if (m_redoBuffer == nullptr)
|
||||
return false;
|
||||
ResetBuffer();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -336,7 +336,7 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
/** @var Next write offset. */
|
||||
/** @var Buffer size. */
|
||||
uint32_t m_bufferSize;
|
||||
|
||||
/** @var Next write offset. */
|
||||
|
|
|
|||
Loading…
Reference in New Issue