Commit Graph

2 Commits

Author SHA1 Message Date
Jan Provaznik 7b22381603 Reschedule commits_count background migration
We still have >100K unmigrated MergeRequestDiffs
which don't have commits_count set yet (see
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/17567#note_61904891)

This migration re-schedules the original background migration.
To assure that records are not processed twice, records with
commits_count set are skipped.

Related to #41698 and !17567
2018-03-09 09:56:49 +01:00
Jan Provaznik e6a1db6d9e Denormalize commits count for merge request diffs
For each MR diff an extra 'SELECT COUNT()' is executed
to get number of commits for the diff. Overall time to get counts for
all MR diffs may be quite expensive. To speed up loading of MR info,
information about number of commits is stored in a MR diff's extra column.

Closes #38068
2018-01-10 20:40:02 +01:00