Skip to main content
Level 3
Oct 16, 2015 2:26 AM UTC
Solved

SMTP can only send RFC822 messages : Unable to send emails from AEM 6.0 (war) deployed on JBoss 7.1

 
    
I deployed AEM 6.0 war (SP1) on JBoss 7.1 version. When i'm running "Request for Activation" (or any other custom java program for sending emails) workflow on any page, it give me the below error and it doesn't send email. I've configured SMTP correctly. Also, i tried to run a custom java program to send emails, it's throwing the same error. I was able to send emails with the same custom java program when i run that from eclipse.

javax.mail.MessagingException: SMTP can only send RFC822 messages
at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:1080)
at com.hds.cq.obc.CustomSendEmailProcess.sendEmail(CustomSendEmailProcess.java:119)
at com.hds.cq.obc.CustomSendEmailProcess.execute(CustomSendEmailProcess.java:67)
at com.day.cq.workflow.compatibility.CQWorkflowProcessRunner.execute(CQWorkflowProcessRunner.java:93)
at com.adobe.granite.workflow.core.job.HandlerBase.executeProcess(HandlerBase.java:208)
at com.adobe.granite.workflow.core.job.JobHandler.process(JobHandler.java:140)
at org.apache.sling.event.jobs.JobUtil$1.run(JobUtil.java:365)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:744)
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Sham_HC
Sham_HCAccepted solution
Level 10
Oct 16, 2015 2:26 AM UTC

RahulMengjiD wrote...

Hi Sham,

I'm getting the error even when i don't install any custom code on the AEM application (Just deployed aem-6.0 war file on Jboss 7.1). Since it was not working on workflow (request for activation) i thought i would write a custom class to send email but was still facing the same issue.

 


recently had customer case & was occurring only in application server. Further investigation revealed the cause was as I specified earlier.  Please file daycare and attach output of Javax.mail from definder plugin

5 replies

Sham_HC
Sham_HCAccepted solution
Level 10
Oct 16, 2015 2:26 AM UTC

RahulMengjiD wrote...

Hi Sham,

I'm getting the error even when i don't install any custom code on the AEM application (Just deployed aem-6.0 war file on Jboss 7.1). Since it was not working on workflow (request for activation) i thought i would write a custom class to send email but was still facing the same issue.

 


recently had customer case & was occurring only in application server. Further investigation revealed the cause was as I specified earlier.  Please file daycare and attach output of Javax.mail from definder plugin

Translate
Level 3
Oct 16, 2015 2:26 AM UTC

Hi Sham,

I'm getting the error even when i don't install any custom code on the AEM application (Just deployed aem-6.0 war file on Jboss 7.1). Since it was not working on workflow (request for activation) i thought i would write a custom class to send email but was still facing the same issue.

Translate
Sham_HC
Level 10
Oct 16, 2015 2:26 AM UTC

You might have custom bundle exporting javax.mail  make sure you export only custom classes & not javax.mail.

Translate
Level 3
Oct 16, 2015 2:26 AM UTC

I tried the custom email java class for sending emails but it still throws the same error :(

Translate
smacdonald2008
Level 10
Oct 16, 2015 2:26 AM UTC

This community article creates an OSGi service that sends email for AEM:

http://helpx.adobe.com/experience-manager/using/creating-custom-cq-email-services.html

It works as it was tested on the versions specified at the start of the article. 

Translate