storage: start replicating the partition which is furthest behind
This fixes the following case when the backup is far behing the upstream DB, and there are transactions being committed at the same time: 1. replicate partition 0 2. replicate partition 0 3. replicate partition 1 4. replicate partition 0 5. replicate partition 1 6. replicate partition 2 7. replicate partition 0 ... and so on in a quadratic way. When the upstream activity was too high, the backup could even be stuck looping on the first partitions.
Showing
Please register or sign in to comment