Sending email-ext messages to multiple recipients with friendly names
The Answer
As it turns out, some of the email addresses in the recipients list were also listed in the Jenkins/Email-Ext "Excluded Recipients" list.
This list is found under Manage Jenkins >> Configure System >> Extended E-mail Notification >> Excluded Recipients
There is no output from email-ext or the job's console to indicate this was the case, so it took time to track down.
I may open an enhancement request with the plugin owner to add some console output related to indicating whether excluded recipients are configured on the job.
Conclusion
Just to be clear: email-ext DOES support using friendly display names in the following formats:
Development <[email protected]>
or "Development" <[email protected]>
Multiples are supported as the usual comma separated list.
I had to do this as well with friendly names to pick up some email lists from jenkins. Below is the syntax that worked for me. I declared primaryOwnerEmail and secondaryOwners [list of emails] and pulled them in the 'to:' line below.
stage ("Notify Developers of Success"){
env.ForEmailPlugin = env.WORKSPACE
emailext attachmentsPattern: 'Checkmarx\\Reports\\*.pdf',
to: "${primaryOwnerEmail},${secondaryOwners}",
subject: "${env.JOB_NAME} - (${env.BUILD_NUMBER}) Finished Successfuly!",
body: "Check console output at ${env.BUILD_URL} to view the results"
}