diff --git a/backend/src/app/migrations.clj b/backend/src/app/migrations.clj index 6778316e5e..fe517762aa 100644 --- a/backend/src/app/migrations.clj +++ b/backend/src/app/migrations.clj @@ -465,6 +465,15 @@ {:name "0145-fix-plugins-uri-on-profile" :fn mg0145/migrate} + {:name "0145-mod-audit-log-table" + :fn (mg/resource "app/migrations/sql/0145-mod-audit-log-table.sql")} + + {:name "0145-mod-audit-log-table" + :fn (mg/resource "app/migrations/sql/0145-mod-audit-log-table.sql")} + + {:name "0146-mod-audit-log-table" + :fn (mg/resource "app/migrations/sql/0146-mod-audit-log-table.sql")} + {:name "0146-mod-access-token-table" :fn (mg/resource "app/migrations/sql/0146-mod-access-token-table.sql")} diff --git a/backend/src/app/migrations/sql/0145-mod-audit-log-table.sql b/backend/src/app/migrations/sql/0145-mod-audit-log-table.sql new file mode 100644 index 0000000000..6d95ecc6af --- /dev/null +++ b/backend/src/app/migrations/sql/0145-mod-audit-log-table.sql @@ -0,0 +1,2 @@ +CREATE INDEX audit_log__created_at__idx ON audit_log(created_at) WHERE archived_at IS NULL; +CREATE INDEX audit_log__archived_at__idx ON audit_log(archived_at) WHERE archived_at IS NOT NULL; diff --git a/backend/src/app/migrations/sql/0145-add-audit-log-telemetry-index.sql b/backend/src/app/migrations/sql/0146-mod-audit-log-table.sql similarity index 100% rename from backend/src/app/migrations/sql/0145-add-audit-log-telemetry-index.sql rename to backend/src/app/migrations/sql/0146-mod-audit-log-table.sql