364 Patterns: Implementing Self-Service in an SOA Environment
Figure 11-2 Using mediation in the bus
11.2.2 Object model
The sequence diagram in Figure 11-3 shows how the Mail Service proxy sends
the e-mail message to MailService using JMS. Note that the application is
unaware that the ultimate receiver of the message requires XML format. The use
of the ESB makes the format transformation transparent to the sender.
Figure 11-3 Sequence diagram for sending e-mail message to MailService
1) The createCustomer() method in the Processor class is invoked.
1.1) createCustomer() invokes the sendActivationMail() method in the
MailService class, passing the customer information from the
registration.
Self Service Application
Processor EJB Module
Mail
Sender
MDB
Mail Service
Proxy
MailServiceEJB Module
To SMTP Ma il
Service
MailService Application
Service Integration Bus
Queue
Destination
JMS Msg
Act.
Spec.
JMS MsgJMS Msg
Mediation
TXT XML
1: createCustomer
1.1: sendActivationMail
1.1.1: sendMail
1.1.2 createTextMessage
1.1.4 setText
<<return>>
sendActivationMail
:Processor
:MailService
:Session
:MessageProducer
:TextMessage
<<return>>
1.1.3 createTextMessage
<<return>>
1.1.5 setText
1.1.6 createProducer
<<return>>
1.1.7 createProducer
<<return>>
1.1.9 send
1.1.8 send

Get Patterns: Implementing Self-Service in an SOA Environment now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.