(r *logrepl.LogicalReplicator)
| 907 | } |
| 908 | |
| 909 | func waitForRunning(r *logrepl.LogicalReplicator) error { |
| 910 | start := time.Now() |
| 911 | for { |
| 912 | if r.Running() { |
| 913 | break |
| 914 | } |
| 915 | |
| 916 | if time.Since(start) > time.Second { |
| 917 | return errors.New("Replication did not start") |
| 918 | } |
| 919 | time.Sleep(10 * time.Millisecond) |
| 920 | } |
| 921 | |
| 922 | return nil |
| 923 | } |
| 924 | |
| 925 | func waitForCaughtUp(r *logrepl.LogicalReplicator) error { |
| 926 | log.Println("Waiting for replication to catch up") |
no test coverage detected