diff options
author | Jan Provaznik <jprovaznik@gitlab.com> | 2018-05-27 22:02:47 +0200 |
---|---|---|
committer | Jan Provaznik <jprovaznik@gitlab.com> | 2018-06-05 20:37:01 +0200 |
commit | fc916b068199f2624c5b9cfeb0389760448910ff (patch) | |
tree | 08a3c4d3cedbdf02cec6e247def0598243ea2c54 /db | |
parent | 538110740acc1768315af097ef74213a6d8953d2 (diff) | |
download | gitlab-ce-fc916b068199f2624c5b9cfeb0389760448910ff.tar.gz |
Migrate jobs in object_storage_upload queue
Diffstat (limited to 'db')
-rw-r--r-- | db/post_migrate/20180603190921_migrate_object_storage_upload_sidekiq_queue.rb | 16 | ||||
-rw-r--r-- | db/schema.rb | 2 |
2 files changed, 17 insertions, 1 deletions
diff --git a/db/post_migrate/20180603190921_migrate_object_storage_upload_sidekiq_queue.rb b/db/post_migrate/20180603190921_migrate_object_storage_upload_sidekiq_queue.rb new file mode 100644 index 00000000000..57bee6269b9 --- /dev/null +++ b/db/post_migrate/20180603190921_migrate_object_storage_upload_sidekiq_queue.rb @@ -0,0 +1,16 @@ +class MigrateObjectStorageUploadSidekiqQueue < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + disable_ddl_transaction! + + def up + sidekiq_queue_migrate 'object_storage_upload', to: 'object_storage:object_storage_background_move' + end + + def down + # do not migrate any jobs back because we would migrate also + # jobs which were not part of the 'object_storage_upload' + end +end diff --git a/db/schema.rb b/db/schema.rb index b7d7cd89c14..f6fb1c92f8d 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 20180531220618) do +ActiveRecord::Schema.define(version: 20180603190921) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" |