summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-08-22 12:47:37 +0200
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-08-22 12:47:37 +0200
commit8b4a335ff1b0c7f4f575e63b6399889faec28456 (patch)
treeb34b89f6db2cdec483f3527c4949855ed24756c5 /db
parent193b199672f5229dd6d2cff30fc8c794bb774bbd (diff)
downloadgitlab-ce-8b4a335ff1b0c7f4f575e63b6399889faec28456.tar.gz
Add migration that migrates CI/CD queues
Diffstat (limited to 'db')
-rw-r--r--db/post_migrate/20170822101017_migrate_pipeline_sidekiq_queues.rb14
-rw-r--r--db/schema.rb2
2 files changed, 15 insertions, 1 deletions
diff --git a/db/post_migrate/20170822101017_migrate_pipeline_sidekiq_queues.rb b/db/post_migrate/20170822101017_migrate_pipeline_sidekiq_queues.rb
new file mode 100644
index 00000000000..48fa3af0c60
--- /dev/null
+++ b/db/post_migrate/20170822101017_migrate_pipeline_sidekiq_queues.rb
@@ -0,0 +1,14 @@
+class MigratePipelineSidekiqQueues < ActiveRecord::Migration
+ include Gitlab::Database::MigrationHelpers
+
+ DOWNTIME = false
+
+ def up
+ sidekiq_queue_migrate 'build', to: 'pipeline_default'
+ sidekiq_queue_migrate 'pipeline', to: 'pipeline_default'
+ end
+
+ def down
+ sidekiq_queue_migrate 'pipeline_default', to: 'pipeline'
+ end
+end
diff --git a/db/schema.rb b/db/schema.rb
index 80f8cde1818..d22e8235a09 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: 20170820100558) do
+ActiveRecord::Schema.define(version: 20170822101017) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"