Adds `#build_notification_recipients` to `NotificationRecipientService`
that returns the `NotificationRecipient` objects in order to be able to
access the new attribute `reason`.
This new attribute is used in the different notifier methods in order to
add the reason as a header: `X-GitLab-NotificationReason`.
Only the reason with the most priority gets sent.
1. Never send a pipeline email to anyone other than the user who created
the pipeline.
2. Only send pipeline success emails to people with the custom
notification setting for enabled. Watchers and participants will
never receive this.
3. When custom settings are unset (for new settings and legacy ones),
act as if failed_pipeline is set.
This slightly changes the semantics of the 'New Issue' and 'New MR' events to
include new mentions in edited Mentionables.
An alternative would be to introduce 'Issue updated' and 'MR updated' events,
but that would lead to questions about why those events were only available
to new mentions, and not existing mentions as well, so hold off for now.