Skip to content

Hardcode pg_rewind retrying (up-to 5m)#60

Merged
VSpike merged 1 commit intogocardless-v0.17.0+from
CI-1290/hardcode_pgrewind_params
Mar 22, 2022
Merged

Hardcode pg_rewind retrying (up-to 5m)#60
VSpike merged 1 commit intogocardless-v0.17.0+from
CI-1290/hardcode_pgrewind_params

Conversation

@VSpike
Copy link

@VSpike VSpike commented Mar 21, 2022

  1. Retry pgrewind #14

Retry pg_rewind for up-to 5m after the first attempt. This allows us to
handle the followed database booting for a moment before falling back to
the more expensive pg_basebackup.

This comes as a crappier alternative to [1], where we were creating
proper configuration values. We want to try this before we attempt to
create a more mature setup, as we intend to leave that work for whenever
we upstream our cascading replication.

1. #14

Retry pg_rewind for up-to 5m after the first attempt. This allows us to
handle the followed database booting for a moment before falling back to
the more expensive pg_basebackup.

This comes as a crappier alternative to [1], where we were creating
proper configuration values. We want to try this before we attempt to
create a more mature setup, as we intend to leave that work for whenever
we upstream our cascading replication.
@VSpike VSpike self-assigned this Mar 21, 2022
@VSpike VSpike requested a review from dyson March 21, 2022 20:22
Copy link

@dyson dyson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gave this a quick test and pg_rewind is working as expected. I'm not sure there is an easy way to verify the retry without testing in a sufficiently large and busy database but the code looks good to me.

Happy to merge this and if there are any issues it will be discovered quick enough during testing on larger clusters.

@VSpike VSpike merged commit 9340cac into gocardless-v0.17.0+ Mar 22, 2022
@VSpike VSpike deleted the CI-1290/hardcode_pgrewind_params branch March 22, 2022 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants