Added completion notification for project imports
What does this MR do and why?
This MR adds an email to notify users that a for project import has completed, similar to the notification sent out when a Direct Transfer finishes. With the addition of user contribution mapping, no real users exist in an imported project until a group owner reassigns. We want to notify group owners when the import completes so that they can begin that process, and also to be consistent with Direct Transfer.
When user mapping is enabled on an import
- The importing user is notified. If they are also a root group owner who can reassign placeholder users, the email includes a message that they can begin reassigning users with a link to the group members placeholders tab. If not, they are told to inform a group owner that user reassignment can be done and are given a link to view import results (import history).
- Other group owners are also notified that the importing user's import has finished, with a link to begin reassigning users.
When user mapping is not enabled, has not been implemented, or the project is imported to a user namespace
- Only the importing user is notified and given a link to view import results (import history). There is no mention of user reassignment.
- Even if user mapping is enabled on an import, if the project was imported to a user namespace, it does not mention user reassignment because there's no group users page to reassign the single import user.
References
Please include cross links to any resources that are relevant to this MR. This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.
- Implementation of bulk import completed emails: !155262 (merged)
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
User mapping disabled or not yet implemented
Scenario | |
---|---|
GitHub import with user mapping disabled | ![]() |
Gitea import with user mapping disabled | ![]() |
Bitbucket Cloud import, no user mapping has been implemented and no flag exists | ![]() |
User mapping enabled
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
Set up the context to import a project into:
- Import into a group vs a user namespace?
- User mapping enabled, disabled, or use an importer that hasn't had user mapping enabled yet?
- Is the importing user a root group owner or only maintainer rights to import a project?
- Import a 3rd party project.
- Verify the completion email was sent according to the importing context.
Note: There's an issue with the Gitea importer that disables the user mapping imports, even if the feature flags are enabled: #506782 (closed)
If you just want to see the various combinations of email layouts, you can pull this branch and generate mailer previews.
Related to #503953 (closed)