Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
mbryzek committed Jun 6, 2024
1 parent 6263686 commit 9a00f21
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions api/app/invariants/CheckInvariants.scala
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@ class CheckInvariants @Inject() (
def process(): Unit = {
val results = invariants.all.map { i =>
val count = database.withConnection { c =>
i.query
.withDebugging()
.as(SqlParser.long(1).*)(c).headOption.getOrElse(0L)
i.query.as(SqlParser.long(1).*)(c).headOption.getOrElse(0L)
}
InvariantResult(i, count)
}
Expand Down
2 changes: 1 addition & 1 deletion api/app/invariants/PurgeInvariants.scala
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ object PurgeInvariants {
Invariant(
s"old_deleted_records_purged_from_$t",
Query(
s"select count(*) from $t where deleted_at < now() - interval '3 months'"
s"select count(*) from $t where deleted_at < now() - interval '1 year'"
)
)
}
Expand Down

0 comments on commit 9a00f21

Please sign in to comment.