feat: add comments
This commit is contained in:
@@ -39,6 +39,7 @@
|
||||
class ConversationWithLabel < ApplicationRecord
|
||||
def self.refresh
|
||||
# https://github.com/scenic-views/scenic#what-about-materialized-views
|
||||
# needs atleast one unuque index for concurrent refresh
|
||||
Scenic.database.refresh_materialized_view(table_name, concurrently: true, cascade: false)
|
||||
end
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@ class AddIndexToConversationWithLabelsView < ActiveRecord::Migration[7.0]
|
||||
disable_ddl_transaction!
|
||||
|
||||
def change
|
||||
# needs atleast one unuque index for concurrent refresh
|
||||
add_index :conversation_with_labels, :id, unique: true, algorithm: :concurrently
|
||||
add_index :conversation_with_labels, :account_id, algorithm: :concurrently
|
||||
add_index :conversation_with_labels, :status, algorithm: :concurrently
|
||||
|
||||
Reference in New Issue
Block a user