summaryrefslogtreecommitdiff
path: root/db/migrate/20210424115725_swap_partitioned_web_hook_logs.rb
diff options
context:
space:
mode:
Diffstat (limited to 'db/migrate/20210424115725_swap_partitioned_web_hook_logs.rb')
-rw-r--r--db/migrate/20210424115725_swap_partitioned_web_hook_logs.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/db/migrate/20210424115725_swap_partitioned_web_hook_logs.rb b/db/migrate/20210424115725_swap_partitioned_web_hook_logs.rb
new file mode 100644
index 00000000000..47b2f81cfae
--- /dev/null
+++ b/db/migrate/20210424115725_swap_partitioned_web_hook_logs.rb
@@ -0,0 +1,15 @@
+# frozen_string_literal: true
+
+class SwapPartitionedWebHookLogs < ActiveRecord::Migration[6.0]
+ include Gitlab::Database::PartitioningMigrationHelpers
+
+ DOWNTIME = false
+
+ def up
+ replace_with_partitioned_table :web_hook_logs
+ end
+
+ def down
+ rollback_replace_with_partitioned_table :web_hook_logs
+ end
+end