When we use Gitlab::SQL::Pattern, this typically relates to a trigram
index. As the 'tri' indicates, we need at least three characters to be
able to use that index.
Labels don't have a trigram index, because we never allow you to search
for them globally: it's always in the context of a project or a
group. In that context, it's just as fast to search for a single
character (in general) because there is already a pretty specific index
being used.
System hooks were not being triggered when projects were archived or
unarchived. Reuse the Projects::UpdateService to automatically
trigger system hooks and increase code reuse.
Prior, an administrator viewing a project's Labels page would see _all_
labels from every project they had access to, rather than only the
labels of that specific project (if any).
This was not an information disclosure, as admins have access to
everything, but it was a performance issue.
If you attempt to move an issue from one project to another and leave
labels blank, LabelsFinder would assign all labels in the new project
to that issue. The issue is that :title is passed along to the Finder,
but since it appears empty no filtering is done. As a result, all
labels in the group are returned. This fix handles that case.
Closes#23668