Small fix

This commit is contained in:
Antonio Andelic 2022-05-24 13:11:11 +00:00
parent 85e7118300
commit c55f4e470a
3 changed files with 16 additions and 6 deletions

View File

@ -1,12 +1,9 @@
#include <Coordination/Defines.h>
#include <Coordination/KeeperServer.h>
#include "Coordination/Changelog.h"
#include "IO/WriteBuffer.h"
#include "config_core.h"
#include <chrono>
#include <condition_variable>
#include <filesystem>
#include <string>
#include <Coordination/KeeperStateMachine.h>

View File

@ -112,7 +112,7 @@ void assertDigest(
{
LOG_FATAL(
&Poco::Logger::get("KeeperStateMachine"),
"Digest for nodes is not matching after {} request of type '{}'.\nExpected digest - {}, actual digest {} (digest version "
"Digest for nodes is not matching after {} request of type '{}'.\nExpected digest - {}, actual digest - {} (digest version "
"{}). Keeper will "
"terminate to avoid inconsistencies.\nExtra information about the request:\n{}",
committing ? "committing" : "preprocessing",

View File

@ -1297,8 +1297,21 @@ struct KeeperStorageSetACLRequestProcessor final : public KeeperStorageRequestPr
return {{zxid, Coordination::Error::ZINVALIDACL}};
std::vector<KeeperStorage::Delta> new_deltas
= {{request.path, zxid, KeeperStorage::SetACLDelta{std::move(node_acls), request.version}},
{request.path, zxid, KeeperStorage::UpdateNodeDelta{[](KeeperStorage::Node & n) { ++n.stat.aversion; }}}};
{
{
request.path,
zxid,
KeeperStorage::SetACLDelta{std::move(node_acls), request.version}
},
{
request.path,
zxid,
KeeperStorage::UpdateNodeDelta
{
[](KeeperStorage::Node & n) { ++n.stat.aversion; }
}
}
};
digest = storage.calculateNodesDigest(digest, new_deltas);