Skip to content
Browse files

unbreaking untrack (WIP)

  • Loading branch information...
1 parent 497f220 commit 51832c3463ae0d073002055a5e0cda42f57290c6 Peter van Hardenberg committed Apr 26, 2011
Showing with 4 additions and 4 deletions.
  1. +1 −1 client.rb
  2. +3 −3 pg.rb
View
2 client.rb
@@ -33,7 +33,7 @@ def get_database
end
def promote(leader_url)
- http_put "#{@database_sha}/promote/#{sha(leader_url)}"
+ http_put "#{@database_sha}/promote"
end
protected
View
6 pg.rb
@@ -42,7 +42,7 @@ def untrack
display "Untracking the leader #{follower_db[:name]}"
return unless confirm_command
- promote_to_primary(follower_db, {})
+ untrack(follower_db)
display_info "#{follower_db[:name]} stopped tracking", follower_db[:url]
end
@@ -64,10 +64,10 @@ def reset
private
- def promote_to_primary(follower_db, leader_db)
+ def untrack(follower_db)
return if follower_db[:name].include? "SHARED_DATABASE"
working_display "Promoting" do
- heroku_postgresql_client(follower_db[:url]).promote leader_db[:url]
+ heroku_postgresql_client(follower_db[:url]).promote
end
end

0 comments on commit 51832c3

Please sign in to comment.
Something went wrong with that request. Please try again.