Friday, 31 January 2014

EMAIL SERVER CONFIGURATION IN SOA.



Introduction..... 2
Introduction of  UMS.....
Overview..... 2
Steps..... 2
Test Email Notification.....


Introduction:

This post will explain how we can configure different email servers for sending email notification using SOA.


Overview:


Here we are going to configure Gmail mail server for sending emails.




Introduction Oracle User Messaging Service


Oracle User Messaging Service provides a common service responsible for sending out messages from applications to devices. It also routes incoming messages from devices to applications.

       You can easily send outgoing notifications from a BPEL process flow or invoke outgoing and incoming messages for tasks assigned to users from a human task.




Steps:

1)    Install OpenSSL

Open command prompt and go to OpenSSLHome/bin


2)    Import Certificate


Run following commands to create SSL certificates. Ignore any reported errors. If command hangs, press Ctrl+C to cancel. This will have no impact on certificate import.

*openssl s_client -connect imap.gmail.com:993 > imap.crt
*openssl s_client -connect smtp.gmail.com:465 > smtp.crt





 

 


 
Above command’s will create .crt files under  OpenSSLHome/bin






Edit imap.crt and smtp.crt to remove everything before

·         Everything before —–BEGIN CERTIFICATE—–
·         Everything after —–----END CERTIFICATE—–





Import above two certificates into keystore. Enter your choice of password when prompted for a new and confirmation password.

Note: - You can find keytool executable from JAVA_HOME/bin either in standalone JDK6 or JDEV_HOME/jdk160_18\bin.

·        keytool -import -alias imap.gmail.com -keystore  <your .jks file> -file imap.crt
·        keytool -import -alias smtp.gmail.com -keystore <your .jks file> -file smtp.crt
  
Modify setDomainEnv.cmd from WLS_HOME/user_projects/domains/<soadomain>/bin to specify truststore.
 
-Djavax.net.ssl.trustStore=<path>/Your .jks file location

 -Djavax.net.ssl.trustStorePassword=<password you used>
Save setDomainEnv.cmd



Configure UMS (User Messaging Service)
 
Login to Weblogic Enterprise Manager and open Workflow Notification Properties from SOA>soa-infra>SOA Administration.




Set Notification Mode as Email. Enter your choice of From, Actionable and ReplyTo email addresses.
 


Click on Go to the Message Driver page. From Associated Drivers page, click on Configure Driver.
 


Test Email Notification:


            After restarting the SOA server. Again go to web logic em console.

User Messaging Service->usermessagingdriver -email (soa server1)-> email driver properties->Related links ->Workflow notification properties page-> Related links->Human Workflow engine

Click on Notification Management tab. 



Click on Send Test Notification button.


Enter details and click send. Check whether you are able to receive emails or not if not then check the logs.


































 

  8