diff options
author | Gabriel Mazetto <brodock@gmail.com> | 2018-08-11 02:45:46 +0300 |
---|---|---|
committer | Gabriel Mazetto <brodock@gmail.com> | 2018-08-11 05:15:59 +0300 |
commit | f21e655b61725b972ae80d584a66d6deb53a337d (patch) | |
tree | f9fb191d364e30119eb7c02f65e4eef12936a232 /db/optional_migrations | |
parent | f6d47d0dee0cbbb49f778de9d196c3dae0dbce7f (diff) |
disable_statement_timeout doesn't require any argument anymore
it will decide the method for disable statement_timeout upon
per transaction or per session, based on how it's called.
When calling with a block, block will be executed and it will use
session based statement_timeout, otherwise will default to existing
behavior.
Diffstat (limited to 'db/optional_migrations')
-rw-r--r-- | db/optional_migrations/composite_primary_keys.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/db/optional_migrations/composite_primary_keys.rb b/db/optional_migrations/composite_primary_keys.rb index 7fbc3d4461d..b330da13d43 100644 --- a/db/optional_migrations/composite_primary_keys.rb +++ b/db/optional_migrations/composite_primary_keys.rb @@ -29,7 +29,7 @@ class CompositePrimaryKeysMigration < ActiveRecord::Migration def up return unless Gitlab::Database.postgresql? - disable_statement_timeout(transaction: false) do + disable_statement_timeout do TABLES.each do |index| add_primary_key(index) end @@ -39,7 +39,7 @@ class CompositePrimaryKeysMigration < ActiveRecord::Migration def down return unless Gitlab::Database.postgresql? - disable_statement_timeout(transaction: false) do + disable_statement_timeout do TABLES.each do |index| remove_primary_key(index) end |