@@ -138,26 +138,20 @@ THolder<TEvSchemeShard::TEvModifySchemeTransaction> BackupPropose(
138
138
FillSetValForSequences (
139
139
ss, *sourceDescription.MutableTable (), exportItemPath.Base ()->PathId );
140
140
}
141
- auto forFiltered = [](const auto & list, NKikimrSchemeOp::EPathType type, auto func){
142
- for (const auto & x : list) {
143
- if (x.GetPathType () == type) {
144
- func (x);
141
+ auto cdcDesc = sourceDescription.GetTable ().GetCdcStreams ();
142
+ for (const auto & x : cdcDesc) {
143
+ TPathId pathId = {sourceDescription.GetTable ().GetPathId ().GetOwnerId (), x.GetPathId ().GetLocalId ()};
144
+ auto cdcPathDesc = GetDescription (ss, pathId);
145
+ for (const auto & child : cdcPathDesc.GetChildren ()) {
146
+ if (child.GetPathType () == NKikimrSchemeOp::EPathTypePersQueueGroup) {
147
+ TPathId pathId = {child.GetParentPathId (), child.GetPathId ()};
148
+ ::NKikimrSchemeOp::TPathDescription* newPersQueue = task.MutablePersQueue ()->Add ();
149
+ *newPersQueue = GetDescription (ss, pathId);
145
150
}
146
151
}
147
- };
148
- forFiltered (sourceDescription.GetChildren (), NKikimrSchemeOp::EPathTypeCdcStream,
149
- [&ss, &forFiltered, &task](auto x){
150
- TPathId pathId = {x.GetSchemeshardId (), x.GetPathId ()};
151
- auto desc = GetDescription (ss, pathId);
152
- forFiltered (desc.GetChildren (), NKikimrSchemeOp::EPathTypePersQueueGroup,
153
- [&ss, &task](auto y){
154
- TPathId pathId = {y.GetSchemeshardId (), y.GetPathId ()};
155
- ::NKikimrSchemeOp::TPathDescription* newPersQueue = task.MutablePersQueue ()->Add ();
156
- *newPersQueue = GetDescription (ss, pathId);
157
- }
158
- );
159
- }
160
- );
152
+ }
153
+
154
+ Cerr << " tsz: " << task.GetPersQueue ().size () << Endl;
161
155
task.MutableTable ()->CopyFrom (sourceDescription);
162
156
}
163
157
0 commit comments