BPM for Financial Services Configurations

<< Prev Chapter 1: BPM for Financial Services Configurations Next >>
Configuring Email Notification – Apache James on Linux

Apache James is a Mail Server that is used to send emails from Linux , the scope of this section would be to send emails from BPM routed through Apache James

Download Apache James Server Binary (james-2.3.2) from http://james.apache.org/ and unzip the file to following directory /home/your-system-name/Oracle/

Start SOA BPM Server. check if sendmail is already running if yes , we need to kill the process or else we will not be able to start james ,

please do not get confused my system name is also james :-)

[root@james fmw]# netstat -pant
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name    
tcp        0      0 127.0.0.1:631           0.0.0.0:*               LISTEN      1250/cupsd          
tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN      994/sendmail: accep 
[root@james fmw]# kill 994

Starting Apache James on Linux

[root@james bin]# ./run.sh
Using PHOENIX_HOME:   /home/james/Oracle/james-2.3.2
Using PHOENIX_TMPDIR: /home/james/Oracle/james-2.3.2/temp
Using JAVA_HOME:      /home/james/Oracle/jdk1.6.0_30/
Running Phoenix:
Phoenix 4.2
James Mail Server 2.3.2
Remote Manager Service started plain:4555
POP3 Service started plain:110
SMTP Service started plain:25
NNTP Service started plain:119
FetchMail Disabled
Adding users to James Mail Server and Configure Domain
[james@james james-2.3.2]$ telnet localhost 4555
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
JAMES Remote Administration Tool 2.3.2
Please enter your login and password
Login id:
root
Password:
root ( remember this is NOT your system root password )
Welcome root. HELP for a list of commands
adduser jcooper welcome1
User jcooper added
adduser jstein welcome1
User jstein added
adduser cdoyle welcome1
User cdoyle added
adduser wfaulk welcome1
User wfaulk added
adduser jlondon welcome1
User jlondon added
listusers
Existing accounts 5
user: jstein
user: jlondon
user: wfaulk
user: jcooper
user: cdoyle
quit
Bye
Connection closed by foreign host.

We will be using jamesbank.com as our domain name so this needs to be configured.

[root@james SAR-INF]# pwd
/home/james/Oracle/james-2.3.2/apps/james/SAR-INF
[root@james SAR-INF]# sudo gedit config.xml

Once config.xml is opened in the edit more add the following lines marked in bold

<servernames autodetect="true" autodetectIP="true">
<servername>localhost</servername>
<servername>jamesbank.com</servername>
<servername>james</servername>
</servernames>

Add Entry to Host file

[root@james SAR-INF]# sudo gedit /etc/hosts
127.0.0.1       localhost    james    jamesbank.com

Now we are pretty much done on Linux side to make james working

Configuring Enterprise Manager to Send EMails

Its assumed that you have already seeded Jcooper, Jstein , JLondon, Wfaulk, CDoyle and other users to the soa bpm user list if not have a quick look at this article.

login to EM (http://localhost:7001/em/) as weblogic , Select User Messaging Services -> User Messaging Email Driver , Map the following

Sender Address = wfaulk@jamesbank.com
Default Sender Address = wfaulk@jamesbank.com
Mail Access Protocol = POP3
Receive Folder = INBOX
Outgoing Mail Server = jamesbank.com
Outgoing Default Mail address = wfaulk@jamesbank.com
Outgoing password = welcome1 (use clear text)
Outgoing Mail Server port = 110
Incoming Mail Ids = jcooper@jamesbank.com
Incoming User Id = jcooper
Incoming password = welcome1 (use clear text)

then click on Apply ,

Screenshot from 2013-01-27 12:01:32

Note you can replace jcooper and wfaulk with any generic name such as BpelAdmin or SoaAdmin or Notification Services @jamesbank.com as you wish

Select farm_fmw_domain -> SOA -> soa_infra -> SOA Administration -> Workflow Config -> Workflow Notification properties , set from, reply to and actionable address

Screenshot from 2013-01-27 12:05:34

Install and configure thunderbird for jcooper@jamesbank.com
[root@james SAR-INF]# yum install thunderbird

this will install thunderbird , launch the mail client and add account

Account Name = jcooper@jamesbank.com
Email Address = jcooper@jamesbank.com
Your Name = jcooper
Server Name = jamesbank.com
Port = 110
user name = jcooper
connection security = none
Authentication Method = Password transmitted insecurely
Outgoing server = SMTP
Server Name = jamesbank.com
Port = 25
username = jcooper
password = welcome1

Screenshot from 2013-01-27 12:11:41

Wiring Notification a BPM Process

To test email let us create a simple Synchronous BPM process, Drag and Drop Notification between start and end , deploy the application and test it.

Screenshot from 2013-01-27 12:17:08

Now once the process is completed we should be able to see the test mail,

Note it is recommended that you have a generic process that can take input parameters as TO Email Id, From Email Id, Subject and Body , then this can re-used across many different processes

Screenshot from 2013-01-27 12:20:09

to Stop Apache James

/home/james/Oracle/james-2.3.2/bin
[root@james bin]# ./phoenix.sh stop
Using PHOENIX_HOME:   /home/james/Oracle/james-2.3.2
Using PHOENIX_TMPDIR: /home/james/Oracle/james-2.3.2/temp
Using JAVA_HOME:      /home/james/Oracle/jdk1.6.0_30/
Shutting down Phoenix:
About Author

Author Details , please expect BPM for Financial Services Book releasing soon .