diff options
author | Felipe Artur <felipefac@gmail.com> | 2019-02-13 17:31:14 -0200 |
---|---|---|
committer | Felipe Artur <felipefac@gmail.com> | 2019-02-13 17:31:14 -0200 |
commit | 26f40aefb09b96538fa99f74d46542ad39bb1679 (patch) | |
tree | d0019bab5871ba7ac76820ca70b26cbc57be60a6 /db/migrate | |
parent | e2aa332504f6cd9eebaa30dfeb71edcea6f9495a (diff) | |
download | gitlab-ce-26f40aefb09b96538fa99f74d46542ad39bb1679.tar.gz |
Code improvements
Diffstat (limited to 'db/migrate')
-rw-r--r-- | db/migrate/20190211131150_add_state_id_to_issuables.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/db/migrate/20190211131150_add_state_id_to_issuables.rb b/db/migrate/20190211131150_add_state_id_to_issuables.rb index d23c946cf88..440f577e1a3 100644 --- a/db/migrate/20190211131150_add_state_id_to_issuables.rb +++ b/db/migrate/20190211131150_add_state_id_to_issuables.rb @@ -8,9 +8,9 @@ class AddStateIdToIssuables < ActiveRecord::Migration[5.0] # 2019-02-12 Gitlab.com issuable numbers # issues count: 13587305 # merge requests count: 18925274 - # Using this 50000 as batch size should take around 13 hours + # Using this 25000 as batch size should take around 26 hours # to migrate both issues and merge requests - BATCH_SIZE = 50000 + BATCH_SIZE = 25000 DELAY_INTERVAL = 5.minutes.to_i class Issue < ActiveRecord::Base @@ -26,8 +26,8 @@ class AddStateIdToIssuables < ActiveRecord::Migration[5.0] end def up - add_column :issues, :state_id, :integer, limit: 1 - add_column :merge_requests, :state_id, :integer, limit: 1 + add_column :issues, :state_id, :integer, limit: 2 + add_column :merge_requests, :state_id, :integer, limit: 2 # Is this safe? # Added to avoid an warning about jobs running inside transactions. |