Question

Exception handling for SendEmailNotification activity

Hi,

PEGA has modified “SendEmailNotification” activity in 8.x version, and only one java step inside the activity. When any exception encountered during the execution of the activity that exception is captured in "EmailException" parameter.And our calling custom activity is looking inside the "EmailException" for the invalid email address name which is causing the issue.But EmailException parameter does not have the details of invalid address.

Could you please help me to understand , how we will get the invalid email address in the "EmailException" parameter.So our Custom activity can fetch the details of invalid address and display to the screen.

Thanks in advanced.

Regards,

Dileep Kumar

***Edited by Moderator: Lochan to update platform capability tags***

Comments

Keep up to date on this post and subscribe to comments

Pega
July 2, 2019 - 8:50am

Hi Dileep,

As it is an available rule,You can add one more java step before the actual java step to check if the emailaddress is valid.You can refer to the OOTB ValidEmailAddress edit validate rule.

July 2, 2019 - 1:20pm

Hi,

Thanks for your suggestion. We are  already diplaying below  technical exception on the screen-

com.pega.pegarules.pub.PRRuntimeException: Caught unhandled exception : Unable to send email due to : 250 2.0.0 x5R5ANsP012515 Message accepted for delivery  .

But we are looking the invalid email address value inside the "EmailException" property, so we can customize the message.

July 3, 2019 - 4:28am

Hi Team,

Please advise why below properties are not populated when there is an exception encountered while sending an email.

pySmtpResponse, pySmtpDebugInfo

Response Page structure in case of email exception is as below (but pySmtpResponse & pySmtpDebugInfo properties are not populated):

<?xml version="1.0"?>
<pagedata>
<pxObjClass>Data-EmailClientResponse</pxObjClass>
<pyErrorMessage>Caught unhandled exception : Unable to send email due to : Invalid Addresses</pyErrorMessage>
<pzStatus>valid</pzStatus>
</pagedata>

Activity: @baseclass.SendEmailNotification RS:Pega-IntegrationEngine:08-01-01

Regards,
Mithun Naik

October 10, 2019 - 8:14am

we are having similar issue in pega 82, do we have any solution or hotfix for this issue?