diff options
Diffstat (limited to 'db/migrate/20200715135130_create_vulnerability_historical_statistics.rb')
-rw-r--r-- | db/migrate/20200715135130_create_vulnerability_historical_statistics.rb | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/db/migrate/20200715135130_create_vulnerability_historical_statistics.rb b/db/migrate/20200715135130_create_vulnerability_historical_statistics.rb deleted file mode 100644 index 6afa123c341..00000000000 --- a/db/migrate/20200715135130_create_vulnerability_historical_statistics.rb +++ /dev/null @@ -1,34 +0,0 @@ -# frozen_string_literal: true - -class CreateVulnerabilityHistoricalStatistics < ActiveRecord::Migration[6.0] - include Gitlab::Database::MigrationHelpers - - INDEX_NAME = 'index_vuln_historical_statistics_on_project_id_and_date' - - DOWNTIME = false - - def up - with_lock_retries do - create_table :vulnerability_historical_statistics do |t| - t.timestamps_with_timezone null: false - t.references :project, null: false, index: false, foreign_key: { on_delete: :cascade } - t.integer :total, default: 0, null: false - t.integer :critical, default: 0, null: false - t.integer :high, default: 0, null: false - t.integer :medium, default: 0, null: false - t.integer :low, default: 0, null: false - t.integer :unknown, default: 0, null: false - t.integer :info, default: 0, null: false - t.date :date, null: false - t.integer :letter_grade, limit: 1, null: false - t.index [:project_id, :date], unique: true, name: INDEX_NAME - end - end - end - - def down - with_lock_retries do - drop_table :vulnerability_historical_statistics - end - end -end |