Merge pull request #47743 from ucasfl/remove

remove unused code
This commit is contained in:
robot-ch-test-poll4 2023-03-20 17:43:41 +01:00 committed by GitHub
commit 91f8901cd6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -9213,30 +9213,4 @@ template std::optional<EphemeralLockInZooKeeper> StorageReplicatedMergeTree::all
const std::vector<String> & zookeeper_block_id_path,
const String & zookeeper_path_prefix) const;
#if 0
PartsTemporaryRename renamed_parts(*this, "detached/");
MutableDataPartsVector loaded_parts = tryLoadPartsToAttach(partition, attach_part, query_context, renamed_parts);
/// TODO Allow to use quorum here.
ReplicatedMergeTreeSink output(*this, metadata_snapshot, 0, 0, 0, false, false, query_context,
/*is_attach*/true);
for (size_t i = 0; i < loaded_parts.size(); ++i)
{
const String old_name = loaded_parts[i]->name;
output.writeExistingPart(loaded_parts[i]);
renamed_parts.old_and_new_names[i].old_name.clear();
LOG_DEBUG(log, "Attached part {} as {}", old_name, loaded_parts[i]->name);
results.push_back(PartitionCommandResultInfo{
.partition_id = loaded_parts[i]->info.partition_id,
.part_name = loaded_parts[i]->name,
.old_part_name = old_name,
});
}
#endif
}