E-mail Service Configuration in ForgeRock OpenAM

In a less than 2 minute video that follows, you’ll see me setting up E-mail service in ForgeRock OpenAM, a facility that is used by OpenAM features such User Self Registration. Because I know for certain I’ll have to refer to this video on a number of occasions in future while demonstrating other capabilities of OpenAM, I’ve decided to keep this video tutorial separate and independent. It’s tiny, of course:

Enjoy!

2 comments

  • Abhishek Bajaj

    Hi Rajesh,

    Facing below error :

    org.forgerock.openidm.external.email.impl.EmailClient$1 run
    SEVERE: Unable to send message
    org.forgerock.json.resource.InternalServerErrorException: Failed to send email
    at org.forgerock.openidm.external.email.impl.EmailClient.send(EmailClient.java:289)
    at org.forgerock.openidm.external.email.impl.EmailClient.access$000(EmailClient.java:42)
    at org.forgerock.openidm.external.email.impl.EmailClient$1.run(EmailClient.java:165)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
    Caused by: com.sun.mail.util.MailConnectException: Couldn’t connect to host, port: smtp.gmail.com, 587; timeout 300000;
    nested exception is:
    java.net.ConnectException: Connection refused: connect
    at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:2194)
    at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:726)
    at javax.mail.Service.connect(Service.java:366)
    at javax.mail.Service.connect(Service.java:246)
    at javax.mail.Service.connect(Service.java:267)
    at org.forgerock.openidm.external.email.impl.EmailClient.send(EmailClient.java:280)
    … 7 more
    Caused by: java.net.ConnectException: Connection refused: connect
    at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)
    at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:85)
    at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
    at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
    at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
    at java.net.Socket.connect(Socket.java:589)
    at com.sun.mail.util.WriteTimeoutSocket.connect(WriteTimeoutSocket.java:113)
    at com.sun.mail.util.SocketFetcher.createSocket(SocketFetcher.java:350)
    at com.sun.mail.util.SocketFetcher.getSocket(SocketFetcher.java:238)
    at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:2160)
    … 12 more

    Please help me out

Leave a Reply

Your email address will not be published. Required fields are marked *