Process less number of commits for squash commit message calculating
In order to calculate default_squash_commit_message
and commits_without_merge_commits
all commits of the MR are processed:
-
default_squash_commit_message
finds the first commit with a description. It's used to suggest the default message for a squash commit -
commits_without_merge_commits
returns all non-merge commits. It's used for allowing a user to select a squash commit message from the existing commit messages
Processing a high number of commits causes performance degradation: #30507 (closed)
We may consider processing a fewer number of commits in order to provide squash-commit message suggestions.
Noto for a developer: since the message is displayed only when an MR can be merged, it'd be reasonable to send these fields only when the MR can be merged