David Taylor
67b23c0e22
PERF: Update all user_histories with one query in UserDestroyer ( #16717 )
...
7a284164 previously switched the UserDestroyer to use find_each when iterating over UserHistory records. Unfortunately, since this logic is wrapped in a transaction, this didn't actually solve the memory usage problem. ActiveRecord maintains references to all modified models within a transaction.
This commit updates the logic to use a single SQL query, rather than updating models one-by-one
2022-05-11 13:39:31 +01:00
..
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-04-28 11:51:03 +02:00
2022-04-28 11:51:03 +02:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-29 10:55:10 +01:00
2022-03-29 10:55:10 +01:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-05-10 10:02:28 -05:00
2022-05-09 09:37:23 +10:00
2022-04-04 22:42:38 +05:30
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-04-06 16:06:45 -04:00
2022-03-01 17:50:50 +00:00
2022-05-11 13:51:51 +05:30
2022-03-01 17:50:50 +00:00
2022-05-09 09:37:23 +10:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-05-10 11:37:52 +02:00
2022-03-01 17:50:50 +00:00
2022-05-11 13:39:31 +01:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00
2022-03-01 17:50:50 +00:00