aboutsummaryrefslogtreecommitdiffstats
path: root/yt
diff options
context:
space:
mode:
authorv-a-zolotov <v-a-zolotov@yandex-team.com>2024-11-21 06:15:31 +0300
committerv-a-zolotov <v-a-zolotov@yandex-team.com>2024-11-21 06:26:38 +0300
commitfedafa631a696950518e56d4c463dca8014ad701 (patch)
tree869632992502d7db7e9db18b6772dbd67b241124 /yt
parent97e1725f1ab6026dfbe6b8d26955ab3f75279f0d (diff)
downloadydb-fedafa631a696950518e56d4c463dca8014ad701.tar.gz
Added cluster field to TRichYPath
Add cluster field to TRichYPath ### Changelog entry Type: feature Component: cpp-sdk commit_hash:eff6ccc4add04d64520c427c194424913ea2dfc4
Diffstat (limited to 'yt')
-rw-r--r--yt/cpp/mapreduce/interface/common.h3
-rw-r--r--yt/cpp/mapreduce/interface/serialize.cpp4
2 files changed, 7 insertions, 0 deletions
diff --git a/yt/cpp/mapreduce/interface/common.h b/yt/cpp/mapreduce/interface/common.h
index d8365c32c0..76df343e68 100644
--- a/yt/cpp/mapreduce/interface/common.h
+++ b/yt/cpp/mapreduce/interface/common.h
@@ -1129,6 +1129,9 @@ struct TRichYPath
/// Specifies columnar mapping which will be applied to columns before transfer to job.
FLUENT_FIELD_OPTION(TRenameColumnsDescriptor, RenameColumns);
+ /// Specifies cluster for the YPath
+ FLUENT_FIELD_OPTION(TString, Cluster);
+
/// Create empty path with no attributes
TRichYPath()
{ }
diff --git a/yt/cpp/mapreduce/interface/serialize.cpp b/yt/cpp/mapreduce/interface/serialize.cpp
index 99f6f46b93..519439d879 100644
--- a/yt/cpp/mapreduce/interface/serialize.cpp
+++ b/yt/cpp/mapreduce/interface/serialize.cpp
@@ -468,6 +468,9 @@ void Serialize(const TRichYPath& path, NYson::IYsonConsumer* consumer)
.DoIf(path.BypassArtifactCache_.Defined(), [&] (TFluentAttributes fluent) {
fluent.Item("bypass_artifact_cache").Value(*path.BypassArtifactCache_);
})
+ .DoIf(path.Cluster_.Defined(), [&] (TFluentAttributes fluent) {
+ fluent.Item("cluster").Value(*path.Cluster_);
+ })
.EndAttributes()
.Value(path.Path_);
}
@@ -499,6 +502,7 @@ void Deserialize(TRichYPath& path, const TNode& node)
DESERIALIZE_ATTR("transaction_id", path.TransactionId_);
DESERIALIZE_ATTR("rename_columns", path.RenameColumns_);
DESERIALIZE_ATTR("bypass_artifact_cache", path.BypassArtifactCache_);
+ DESERIALIZE_ATTR("cluster", path.Cluster_);
Deserialize(path.Path_, node);
}