PERF: Add missing index on `EmailLog#bounced`.

* Also remove index on `user_id_and_created_at` which
  isn't being used alot.
This commit is contained in:
Guo Xiang Tan 2018-08-03 17:07:18 +08:00
parent 280c318c49
commit 6ede7c4623
1 changed files with 6 additions and 0 deletions

View File

@ -0,0 +1,6 @@
class AddIndexEmailLogsOnBounced < ActiveRecord::Migration[5.2]
def change
add_index :email_logs, :bounced
remove_index :email_logs, [:user_id, :created_at]
end
end