Add not null constraints to prometheus_metrics table columns

This commit is contained in:
Arun Kumar Mohan 2019-08-28 06:18:03 -05:00
parent 4e4fcf79c5
commit ab60775216
2 changed files with 10 additions and 2 deletions

View File

@ -0,0 +1,8 @@
class AddNotNullConstraintsToPrometheusMetricsYLabelAndUnit < ActiveRecord::Migration[5.2]
DOWNTIME = false
def change
change_column_null(:prometheus_metrics, :y_label, false)
change_column_null(:prometheus_metrics, :unit, false)
end
end

View File

@ -2869,8 +2869,8 @@ ActiveRecord::Schema.define(version: 2019_09_02_131045) do
t.integer "project_id"
t.string "title", null: false
t.string "query", null: false
t.string "y_label"
t.string "unit"
t.string "y_label", null: false
t.string "unit", null: false
t.string "legend"
t.integer "group", null: false
t.datetime_with_timezone "created_at", null: false