File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Other JSE/JEE APIs and the fly likes SMTPAddressFailedException: 550 5.7.1 Unable to relay    Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "SMTPAddressFailedException: 550 5.7.1 Unable to relay    " Watch "SMTPAddressFailedException: 550 5.7.1 Unable to relay    " New topic
Author

SMTPAddressFailedException: 550 5.7.1 Unable to relay

ani jadhao
Ranch Hand

Joined: Dec 23, 2008
Posts: 62
Hello,
I am facing a problem while sending an email using java mail apis. I am using a m/s smtp exchange server v 5.0 build 2195 . In smtp server settings , I ve placed a domain [my intra net domain]indiaeng.com in allowed list to relay and restart smtp server. And when I send an email to any invalid email id e.g. ajadhao@abcda.com, java mail api continuously try to send the email to this invalid id, causing the component to eat up loads of cpu , impacting performance of system.

Thread-22 | Error sending email:javax.mail.SendFailedException: Invalid Addresses;
nested exception is:
com.sun.mail.smtp.SMTPAddressFailedException: 550 5.7.1 Unable to relay for ajadhao@abcda.com

javax.mail.SendFailedException: Invalid Addresses;
nested exception is:
com.sun.mail.smtp.SMTPAddressFailedException: 550 5.7.1 Unable to relay for ajadhao@abcda.com

at com.sun.mail.smtp.SMTPTransport.rcptTo(SMTPTransport.java:1294)
at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:635)
at javax.mail.Transport.send0(Transport.java:189)
at javax.mail.Transport.send(Transport.java:118)
at com.avaya.icm.transcript.Mailer.sendMail(Mailer.java:133)
at com.avaya.icm.transcript.MailManager.process(MailManager.java:39)
at com.avaya.icm.transcript.TranscriptManager.processFile(TranscriptManager.java:143)
at com.avaya.icm.transcript.TranscriptManager.process(TranscriptManager.java:118)
at com.avaya.icm.transcript.TranscriptManager.run(TranscriptManager.java:87)
Caused by: com.sun.mail.smtp.SMTPAddressFailedException: 550 5.7.1 Unable to relay for ajadhao@indiaeng.com

at com.sun.mail.smtp.SMTPTransport.rcptTo(SMTPTransport.java:1145)



When I remove the indiaeng.com domain from smpt allowed list configuration, the java mail api sends it to the invalid email id only once and return . It doesnt try to send to the invalid email id again.

The is kind a confusing behavior. Can any one please help me in getting the confusion cleared?
thanks
Ani


SCJP 1.4 : 91%
SCWCD 5: 96%
 
 
subject: SMTPAddressFailedException: 550 5.7.1 Unable to relay