ETS is not honoring maxRecipients property sending emails.

Description

The sendMail method allows you to send emails to unlimited number of recipients. For example, in Samigo when you publish an assessment if you check (notify students) you send an email to all the students, and that number could be greater than the maxRecipients you configured in ETS.

2016-10-31 09:11:22,620 ERROR ajp-nio-8013-exec-6 org.sakaiproject.email.impl.BasicEmailService - Email.sendMail: exception: 250 2.0.0 Ok: queued as 5A1142026C com.sun.mail.smtp.SMTPSendFailedException: 250 2.0.0 Ok: queued as 5A1142026C ; nested exception is: com.sun.mail.smtp.SMTPAddressFailedException: 452 4.5.3 Error: too many recipients

Test Plan:
Choose a site with more students than maxrecipients value (by default 100).
Go to Samigo and choose/create one assessment to publish it.
In the publish screen choose send notification option and click publish.

Activity

Show:

Alexandre Ballesté Crevillén February 15, 2017 at 3:53 AM

I tested locally in 11.x that matches with 11.3RC01. It worked fine.

Juanjo Meroño November 18, 2016 at 2:03 AM

It's not easy, you have to connect sakai with a real email server, because the test mode ignores this value, so you can't test that emails with more than maxRecipients recipients are fragmented by maxRecipients value unless you send the email for real disappointed face

The code is not new, is just adding fragmentation in emails that weren't fragmented before. We've got this running in production since last month so I think it's safe.

Molly Kelsey November 17, 2016 at 9:18 AM

How is this QA tested?

Juanjo Meroño October 31, 2016 at 11:01 AM

Yes, usually SMTP servers limit the max number of recipients, and that's why you can configure maxRecipients@org.sakaiproject.email.api.EmailService property to match with your server configuration and avoid reject emails. But in this case the code is ignoring this limit and send the message no matter how many recipients it has.

Neal Caidin October 31, 2016 at 9:09 AM

so with an SMTP server it would not send the email because it went past the maximum number of recipients configured by maxRecipients?

Fixed

Details

Priority

Affects versions

Fix versions

Components

Assignee

Reporter

Created October 31, 2016 at 4:23 AM
Updated April 25, 2018 at 3:18 PM
Resolved November 2, 2016 at 2:58 AM

Flag notifications