I want to send an email to the user
after the successful action pipeline is completed. I have used NotifyEmail
for this but this is not working. The SMTP host is not picked up from the
jboss-properties.xml . My SMTP Server is 172.25.8.13 and it can accept
null username and password.I have set SMTP host in both
jbossesb.sar/jbossesb-properties and
jbossesb-properties in my application folder.
The error is
Code:
2008-08-27 16:18:42,546
INFO [STDOUT] ConsoleNotifier 2008/08/27 04:18:42.546<<CountryDetais><Country
Code="us"><Name>United States of America</Name><Rate>8.33</Rate><ISD>71</ISD>
</Country><Country
Code="in"><Name>India</Name><Rate>0</Rate>
<ISD>91</ISD></Country><Country
Code="au"><Name>Australia</Name><Rate>7.69</Rate><ISD>21</ISD></Country></CountryDetais>>
2008-08-27 16:18:42,562
WARN [org.jboss.soa.esb.helpers.Email] 'org.jboss.soa.esb.mail.smtp.auth'
s
et to an empty value.
2008-08-27 16:18:42,562
INFO [org.jboss.soa.esb.helpers.Email] Initialising mail server sesson.
Pro
perties: {mail.smtp.port=25,
mail.smtp.auth=true, mail.smtp.host=localhost}
2008-08-27 16:18:43,671
ERROR [org.jboss.soa.esb.notification.NotificationList] Can't instantiate
ta
rget <target class="NotifyEmail"
from="Neha.Pandey@lntinfotech.com" sendTo="Neha.Pandey@lntinfotech.com"
subject="Hello">
</target>
org.jboss.soa.esb.notification.NotificationException:
javax.mail.MessagingException: Exception readi
ng response;
nested exception
is:
java.net.SocketException: Connection reset
at org.jboss.soa.esb.notification.NotifyEmail.sendNotification(NotifyEmail.java:127)
at org.jboss.soa.esb.notification.NotificationList.notifyAll(NotificationList.java:164)
at org.jboss.soa.esb.actions.Notifier.notifyOK(Notifier.java:93)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.jboss.soa.esb.listeners.message.ActionProcessorMethodInfo.processSuccess(ActionProcessorMeth
odInfo.java:165)
at org.jboss.soa.esb.listeners.message.OverriddenActionLifecycleProcessor.processSuccess(Overridden
ActionLifecycleProcessor.java:108)
at org.jboss.soa.esb.listeners.message.ActionProcessingPipeline.notifySuccess(ActionProcessingPipel
ine.java:610)
at org.jboss.soa.esb.listeners.message.ActionProcessingPipeline.process(ActionProcessingPipeline.ja
va:384)
at org.jboss.soa.esb.listeners.message.MessageAwareListener$TransactionalRunner.run(MessageAwareLis
tener.java:530)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)
Caused by: javax.mail.MessagingException:
Exception reading response;
nested exception
is:
java.net.SocketException: Connection reset
at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:1611)
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1369)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:412)
at javax.mail.Service.connect(Service.java:310)
at javax.mail.Service.connect(Service.java:169)
at javax.mail.Service.connect(Service.java:118)
at javax.mail.Transport.send0(Transport.java:188)
at javax.mail.Transport.send(Transport.java:118)
at org.jboss.soa.esb.helpers.Email.sendMessage(Email.java:181)
at org.jboss.soa.esb.notification.NotifyEmail.sendEmailNotification(NotifyEmail.java:151)
at org.jboss.soa.esb.notification.NotifyEmail.sendNotification(NotifyEmail.java:115)
... 14 more
Caused by: java.net.SocketException:
Connection reset
at java.net.SocketInputStream.read(SocketInputStream.java:168)
at com.sun.mail.util.TraceInputStream.read(TraceInputStream.java:110)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
at java.io.BufferedInputStream.read(BufferedInputStream.java:235)
at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:88)
at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:1589)
... 24 more
I have set the properties in Jboss-properties.xml
file
Code:
<properties
name="transports" depends="core">
<property name="org.jboss.soa.esb.mail.smtp.host"
value="172.25.8.13"/>
<property name="org.jboss.soa.esb.mail.smtp.user"
value=""/>
<property name="org.jboss.soa.esb.mail.smtp.password"
value=""/>
<property name="org.jboss.soa.esb.mail.smtp.port"
value="25"/>
</properties>
<action name="print-after-csv-tranform" class="org.jboss.soa.esb.actions.SystemPrintln">
<property name="message"
value="[transform_CSV2Smooks_Intermediate_format] Message after CVS
to XML transformation" />
</action>
<action name="print-after-xml-transform" class="org.jboss.soa.esb.actions.SystemPrintln">
<property name="message"
value=">>>> Message after Smooks intermediate xml ->
target xml : " />
</action>
<!-- The next action is for Continuous Integration testing -->
<action name="testStore" class="org.jboss.soa.esb.actions.TestMessageStore"/>
</actions>
</service>
How should i go about this?What is
the problem?
Thanks & Regards,
Neha Pandey
Center of Excellence - SOA Group
L &T Infotech Limited
Gate no. - 5, Technology Center ,
4th Floor - West side
Powai.
Mumbai 400 072.
The information contained in this mail is classified as
( ) L&T Infotech Proprietary
( ) L&T Infotech Confidential
( ) L&T Infotech Internal Use
( ) L&T Infotech General Business
L&T
Infotech Proprietary L&T
Infotech Confidential L&T
Infotech Internal Use Only L&T
Infotech General Business
This Email may contain confidential or privileged information for the intended
recipient (s) If you are not the intended recipient, please do not use
or disseminate the information, notify the sender and delete it from your
system.
______________________________________________________________________