Commit de91c91c authored by Krasimir Angelov's avatar Krasimir Angelov 🔴 Committed by Mayra Cabrera

Remove operations_feature_flags_clients.token column

Related to #35697.
parent 9979f35f
# frozen_string_literal: true
class DropOperationsFeatureFlagsClientsToken < ActiveRecord::Migration[5.2]
include Gitlab::Database::MigrationHelpers
DOWNTIME = false
def up
# Ignored in 12.5 -
remove_column :operations_feature_flags_clients, :token
def down
unless column_exists?(:operations_feature_flags_clients, :token)
add_column :operations_feature_flags_clients, :token, :string # rubocop:disable Migration/AddLimitToStringColumns
add_concurrent_index :operations_feature_flags_clients, [:project_id, :token], unique: true,
name: 'index_operations_feature_flags_clients_on_project_id_and_token'
......@@ -10,7 +10,7 @@
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 2019_11_25_140458) do
ActiveRecord::Schema.define(version: 2019_12_02_031812) do
# These are extensions that must be enabled in order to support this database
enable_extension "pg_trgm"
......@@ -2776,9 +2776,7 @@ ActiveRecord::Schema.define(version: 2019_11_25_140458) do
create_table "operations_feature_flags_clients", force: :cascade do |t|
t.integer "project_id", null: false
t.string "token"
t.string "token_encrypted"
t.index ["project_id", "token"], name: "index_operations_feature_flags_clients_on_project_id_and_token", unique: true
t.index ["project_id", "token_encrypted"], name: "index_feature_flags_clients_on_project_id_and_token_encrypted", unique: true
title: Remove operations_feature_flags_clients.token column
merge_request: 21016
type: other
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment