From 8952e24abaec466f0fa31325b9d4ee6ba787db58 Mon Sep 17 00:00:00 2001 From: Shlomi Noach Date: Wed, 28 Dec 2016 07:42:14 +0200 Subject: [PATCH] rewinding resurrecting at beginning of known logfile; more verbose --- go/logic/migrator.go | 3 +++ go/logic/streamer.go | 2 ++ 2 files changed, 5 insertions(+) diff --git a/go/logic/migrator.go b/go/logic/migrator.go index d333162..74ef84e 100644 --- a/go/logic/migrator.go +++ b/go/logic/migrator.go @@ -307,6 +307,9 @@ func (this *Migrator) applyResurrectedContext() error { return err } + log.Infof("Applied migration min values: [%s]", this.migrationContext.MigrationRangeMinValues) + log.Infof("Applied migration max values: [%s]", this.migrationContext.MigrationRangeMaxValues) + return nil } diff --git a/go/logic/streamer.go b/go/logic/streamer.go index 5451fb0..685b290 100644 --- a/go/logic/streamer.go +++ b/go/logic/streamer.go @@ -114,6 +114,8 @@ func (this *EventsStreamer) InitDBConnections(resurrectedContext *base.Migration return err } if this.migrationContext.Resurrect { + // Rewinding to beginning of logfile: + resurrectedContext.AppliedBinlogCoordinates.LogPos = 4 log.Infof("Resurrection: initiating streamer at resurrected coordinates %+v", resurrectedContext.AppliedBinlogCoordinates) this.initialBinlogCoordinates = &resurrectedContext.AppliedBinlogCoordinates } else {