feat(datasync): add Schedules property to PipelineConfig

Add PipelineSchedules? Schedules parameter to PipelineConfig record between
SyncModes and Transformers for new schedule-based configuration. The existing
SyncModes property is now nullable for backward compatibility during the
transition to the new schedule system.
This commit is contained in:
Joseph Doherty
2026-01-07 00:41:03 -05:00
parent 15cfc1a010
commit 21f598f25c
3 changed files with 64 additions and 21 deletions
@@ -142,7 +142,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true)
// No incremental mode defined
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -212,7 +213,8 @@ public class EtlPipelineFactoryTests
// Missing mass mode
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -243,7 +245,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00"),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -274,7 +277,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -323,7 +327,8 @@ public class EtlPipelineFactoryTests
Destination: new DestinationOverride("bulkMerge", null, null)),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -355,7 +360,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", null, null), // No matchColumns!
null,
null)
@@ -394,7 +400,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -430,7 +437,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -466,7 +474,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -502,7 +511,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -537,7 +547,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -569,7 +580,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true, ReIndex: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -601,7 +613,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
["EXEC sp_BeforeSync"],
null)
@@ -633,7 +646,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
["UPDATE TestTable SET ProcessedFlag = 1 WHERE ProcessedFlag IS NULL"])
@@ -672,7 +686,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -708,7 +723,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -744,7 +760,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true),
["incremental"] = new SyncModeConfig("not-a-valid-timespan") // Invalid!
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -775,7 +792,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig(null, PrePurge: true), // Null offset
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)
@@ -813,7 +831,8 @@ public class EtlPipelineFactoryTests
["mass"] = new SyncModeConfig("-365.00:00:00", PrePurge: true, ReIndex: true),
["incremental"] = new SyncModeConfig("-1.00:00:00")
},
null,
null, // Schedules
null, // Transformers
new DestinationConfig("TestTable", ["Id"], null),
null,
null)