Rules for (automatic) merge request assignment

Description

In a large project, made from different semi-independent codes, it may not be convenient to have a single set of "reviewers" to approve all merge requests. Instead, it would be more appropriate if each merge request is assigned to one or several people, depending on, e.g. which files/directories are modified. This can be done manually when the MR is created/submitted, but the user that creates the MR may not know wo is the "responsible" person.

Proposal

I would like a project setting to specify some rules to automatically assign MR to one or several developers, for example:

  • If the MR touches files in foo/, add A as an assignee. (A knows the code in this directory much better)
  • If the keyword "bar" appears in any commit description, add B as an assignee. (B coded the feature "bar", which is spread across many directories)
  • If C is an author of any commit, add D as an assignee. (D is acting as a kind of mentor for C)
  • ...

This should create a default set of assignees for each MR, but it would always be possible to modify it (at least for users with the right privileges).

Links / references

Asked about it here, but no reply so far.