Skip to content

Commit 34b7712

Browse files
committed
update
1 parent deeb067 commit 34b7712

1 file changed

Lines changed: 5 additions & 12 deletions

File tree

pkg/ccr/job.go

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1018,24 +1018,17 @@ func (j *Job) fullSync() error {
10181018
}
10191019

10201020
if !tableExists {
1021-
// Table has been dropped during full sync
1021+
// Table has been dropped during full sync, wait for recreate (regardless of feature flag)
1022+
// TableDroppedFlag already set by checkTableExistsForTableSync
10221023
if featureResyncOnTableRecreate {
1023-
// Wait for table to be recreated (TableDroppedFlag already set by checkTableExistsForTableSync)
10241024
log.Warnf("table %s.%s has been dropped during full sync, waiting for recreate",
10251025
j.Src.Database, j.Src.Table)
1026-
return nil
10271026
} else {
1028-
// Pause job
1029-
msg := fmt.Sprintf("table %s.%s has been dropped during full sync. Job will be paused.",
1027+
log.Warnf("table %s.%s has been dropped during full sync. Auto-resync disabled, waiting and retry. "+
1028+
"Enable with: -feature_resync_on_table_recreate=true",
10301029
j.Src.Database, j.Src.Table)
1031-
log.Warnf(msg)
1032-
j.progress.SetFullSyncInfo(msg)
1033-
j.progress.Persist()
1034-
if err := j.Pause(); err != nil {
1035-
log.Errorf("failed to pause job: %+v", err)
1036-
}
1037-
return xerror.Errorf(xerror.Normal, msg)
10381030
}
1031+
return nil
10391032
}
10401033

10411034
// Step 1.2.2: Check if table_id changed again (table dropped and recreated during full sync)

0 commit comments

Comments
 (0)