Skip to content

Commit

Permalink
Remove SyncOptionsSignal
Browse files Browse the repository at this point in the history
This did not get wired up in sync_flow.go, but rather than implement it, remove it
We're moving towards requiring all option updates to require pausing first anyways
  • Loading branch information
serprex committed Mar 4, 2024
1 parent 39c6e7e commit e8e1421
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
4 changes: 0 additions & 4 deletions flow/model/signals.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,6 @@ var SyncResultSignal = TypedSignal[*SyncResponse]{
Name: "sync-result",
}

var SyncOptionsSignal = TypedSignal[*protos.SyncFlowOptions]{
Name: "sync-options",
}

var NormalizeSignal = TypedSignal[NormalizePayload]{
Name: "normalize",
}
Expand Down
8 changes: 0 additions & 8 deletions flow/workflows/cdc_flow.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,6 @@ func (w *CDCFlowWorkflowExecution) processCDCFlowConfigUpdate(ctx workflow.Conte

state.SyncFlowOptions.TableMappings = append(state.SyncFlowOptions.TableMappings, flowConfigUpdate.AdditionalTables...)

if w.syncFlowFuture != nil {
_ = model.SyncOptionsSignal.SignalChildWorkflow(ctx, w.syncFlowFuture, state.SyncFlowOptions).Get(ctx, nil)
}

// finished processing, wipe it
state.FlowConfigUpdate = nil
}
Expand All @@ -191,10 +187,6 @@ func (w *CDCFlowWorkflowExecution) addCdcPropertiesSignalListener(
// do this irrespective of additional tables being present, for auto unpausing
state.FlowConfigUpdate = cdcConfigUpdate

if w.syncFlowFuture != nil {
_ = model.SyncOptionsSignal.SignalChildWorkflow(ctx, w.syncFlowFuture, state.SyncFlowOptions).Get(ctx, nil)
}

w.logger.Info("CDC Signal received. Parameters on signal reception:",
slog.Int("BatchSize", int(state.SyncFlowOptions.BatchSize)),
slog.Int("IdleTimeout", int(state.SyncFlowOptions.IdleTimeoutSeconds)),
Expand Down

0 comments on commit e8e1421

Please sign in to comment.