Hi all, I am seeing something odd in CF8. Every once in a while I see the following error message when sending a small batch of single emails one after the other:
Message: A problem occurred when attempting to deliver mail.
Detail: This exception was caused by: com.sun.mail.smtp.SMTPSendFailedException: 421 4.4.2 service timed out.
If there are attachments they will come from a database, and I put the files on the file system and the file names into an array. So, sometimes there are file names in that array and sometimes there aren't. The code is arranged like so:
<cfmail>
body of email
<cfif ArrayLen(attachments)>
<cfmailparam> tags in a loop through the array
</cfif>
</cfmail>
Sometimes this gets that "service timed out" error. If I take the <cfif> tag out it doesn't fail, whether the array is empty or not. It seems that this code works:
<cfif ArrayLen(attachments)>
<cfmail>
body of email
<cfmailparam> tags in a loop through the array
</cfmail>
<cfelse>
<cfmail>
body of email
</cfmail>
</cfif>
It's wordy but it works. Am I losing my mind? How could this make a difference? Is this a bug I don't know about? Thanks!
Message: A problem occurred when attempting to deliver mail.
Detail: This exception was caused by: com.sun.mail.smtp.SMTPSendFailedException: 421 4.4.2 service timed out.
If there are attachments they will come from a database, and I put the files on the file system and the file names into an array. So, sometimes there are file names in that array and sometimes there aren't. The code is arranged like so:
<cfmail>
body of email
<cfif ArrayLen(attachments)>
<cfmailparam> tags in a loop through the array
</cfif>
</cfmail>
Sometimes this gets that "service timed out" error. If I take the <cfif> tag out it doesn't fail, whether the array is empty or not. It seems that this code works:
<cfif ArrayLen(attachments)>
<cfmail>
body of email
<cfmailparam> tags in a loop through the array
</cfmail>
<cfelse>
<cfmail>
body of email
</cfmail>
</cfif>
It's wordy but it works. Am I losing my mind? How could this make a difference? Is this a bug I don't know about? Thanks!