~cytrogen/masto-fe

ref: ef8ca2fd7231f331f6822955b518a25861663b87 masto-fe/db/migrate/20171226094803_more_faster_index_on_notifications.rb -rw-r--r-- 346 bytes
ef8ca2fd — Renaud Chaput Change Dockerfile to upgrade packages when building (#26922) 2 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
# frozen_string_literal: true

class MoreFasterIndexOnNotifications < ActiveRecord::Migration[5.2]
  disable_ddl_transaction!

  def change
    add_index :notifications, [:account_id, :id], order: { id: :desc }, algorithm: :concurrently
    remove_index :notifications, name: :index_notifications_on_id_and_account_id_and_activity_type
  end
end