Skip to content
Snippets Groups Projects
Commit 84567e63 authored by Valery Sizov's avatar Valery Sizov
Browse files

Geo: More reliable disaster recovery

parent 7a555037
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -3,6 +3,9 @@
The latest version of this file can be found at the master branch of the
omnibus-gitlab repository.
 
10.8.0
- Geo: Error when primary promotion fails
10.7.0
- Geo: Increase default WAL standby settings from 30s to 60s
- Geo: Add support for creating a user for the pgbouncer on the Geo DB
Loading
Loading
Loading
Loading
@@ -41,7 +41,7 @@ module Geo
puts 'Promoting the PostgreSQL to primary...'.color(:yellow)
puts
 
run_command("/opt/gitlab/embedded/bin/gitlab-pg-ctl promote")
run_command("/opt/gitlab/embedded/bin/gitlab-pg-ctl promote", live: true).error!
end
 
def reconfigure
Loading
Loading
Loading
Loading
@@ -31,7 +31,9 @@ describe Geo::PromoteToPrimary, '#execute' do
it 'calls all the subcommands' do
is_expected.to receive(:run_command).with('gitlab-ctl reconfigure', live: true).once
is_expected.to receive(:run_command).with('gitlab-rake geo:set_secondary_as_primary', live: true).once
is_expected.to receive(:run_command).with("/opt/gitlab/embedded/bin/gitlab-pg-ctl promote").once
shell_out_object = double.tap { |shell_out_object| expect(shell_out_object).to receive(:error!) }
is_expected.to receive(:run_command).with("/opt/gitlab/embedded/bin/gitlab-pg-ctl promote", live: true).once.and_return(shell_out_object)
 
command.execute
end
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment