Update ReplicatedMergeTreeQuorumWriter.h

This commit is contained in:
Vadim 2018-09-17 15:51:42 +03:00 committed by GitHub
parent 4dee095b9d
commit df9a01585a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -29,6 +29,7 @@ struct ReplicatedMergeTreeQuorumWriter
read(old_added_parts); read(old_added_parts);
} }
/// Write new parts in string with added parts.
std::string write(const std::string & part_name) std::string write(const std::string & part_name)
{ {
WriteBufferFromOwnString out; WriteBufferFromOwnString out;
@ -72,6 +73,7 @@ struct ReplicatedMergeTreeQuorumWriter
added_parts = read_v3(in); added_parts = read_v3(in);
} }
/// Read blocks when node in ZooKeeper suppors multiple partitions.
PartitonIdToPartName read_v2(ReadBufferFromString & in) PartitonIdToPartName read_v2(ReadBufferFromString & in)
{ {
PartitonIdToPartName parts_in_quorum; PartitonIdToPartName parts_in_quorum;
@ -95,6 +97,7 @@ struct ReplicatedMergeTreeQuorumWriter
return parts_in_quorum; return parts_in_quorum;
} }
/// Read added bloks when node in ZooKeeper supports only one partition.
PartitonIdToPartName read_v3(ReadBufferFromString & in) PartitonIdToPartName read_v3(ReadBufferFromString & in)
{ {
PartitonIdToPartName parts_in_quorum; PartitonIdToPartName parts_in_quorum;
@ -110,4 +113,4 @@ struct ReplicatedMergeTreeQuorumWriter
} }
}; };
} }