DE54275 - Maileater error/success emails not working when using custom notification method due to missing values in parameters
search cancel

DE54275 - Maileater error/success emails not working when using custom notification method due to missing values in parameters

book

Article ID: 188111

calendar_today

Updated On:

Products

CA Service Desk Manager CA Service Desk Manager - Mobile Application

Issue/Introduction

When using a custom notification method for maileater, the parameters are not being sent with the notification method. 

It seems that the code in function DoCommand in the PdmMailUtils.class does not deliver the inputs needed for the called process as show in the trace of maileater; for example, the following debug message shows that the -F and -T parameters have no associated values:

2020-04-06 13:12:21:508 DEBUG  [Thread-3] c.c.S.m.c.PdmMailUtils - DoCommand - C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.bat -s "Seq1 Service Desk Change Order Response" -e "[email protected]" -F "" -T ""


STEPS-TO-REPRODUCE (on Windows environment):

1. Create the following batch file in the $NX_ROOT\bin directory:

name of the file: sampleNF1.bat
location of the file: C:\PROGRA~2\CA\SERVIC~1\bin
content of the file:

echo %0 > C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %1 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %2 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %3 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %4 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %5 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %6 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %7 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out
echo %8 >> C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.out

2. Create a notification method as follows:

Symbol: custom_mail_reply
Write to file: No
Supports SMTP: Yes
Record Status: Active
Description: 31791537
Notification Method: C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.bat


3. Create a new mailbox rule to process all change orders, sequence #1, as follows:

Sequence: 1
Mailbox: Default 
Filter: Subject contains
Filter String: [ \t\r\n]change[ \t\r\n]
Ignore Case: Yes
Action: Create/Update Object
Action Object: Change
Minimum Artifact Type:
Reply: custom_mail_reply
Reply Subject: Seq1 Service Desk Change Order Response
Write to stdlog: No
Log Entry Prefix:
Add Subject Line:
In the "1. REPLY SUCCESS" tab:
Success Text: seq 1 Test success 1
Success HTML: seq 1 Test success 2
In the "2. REPLY FAILURE" tab:
Failure Text: seq 1 Test Failure 1
Failure HTML: seq 1 Test Failure 2


4. Set the logging for maileater to TRACE level ( instead of INFO )

5. Create a new change order or open an existing change order. Click on Activities in the menu and select "Manual Notify.. ". Enter a contact (i.e. ServiceDesk) and add it to To Recipients column (ensure that the contact has a valid email address set), click Notify.

6. Check the mailbox of the contact to which the email notification was sent in the previous step (i.e. [email protected]).  Reply to the email that was received such that it is sent back to the maileater.

7. Check maileater_nxd.log. The following message will have been written:

2020-04-06 13:12:21:508 DEBUG  [Thread-3] c.c.S.m.c.PdmMailUtils - DoCommand - C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.bat -s "Seq1 Service Desk Change Order Response" -e "[email protected]" -F "" -T ""

8. Check the output file, sampleNF1.out, for the sampleNF1.bat command.  The parameters received will also show that the value for both the -F and -T parameters is null (i.e. "").
 
C:\PROGRA~2\CA\SERVIC~1\bin\sampleNF1.bat
-s
"Seq1 Service Desk Change Order Response"
-e
"[email protected]"
-F
""
-T
""

Environment

Release : 17.2

Component : SERVICE DESK MANAGER

Reproduced:
(customer) 17.2 RU2 on Linux
(in-house) 17.2 RU5 Windows

Cause

Product defect DE54275

Resolution

Check the Fix Lists of any rollup patches delivered after 17.2 Rollup #7 (17.2 RU7, 17.2.0.7).  In particular, please check 17.2 RU9 (rollup #9, 17.2.0.9).

Additional Information

Release Notes for CA Service Management 17.2

Knowledge article 98428 - How to enable the debug or trace mode for the Service Desk Manager 17.x maileater (pdm_maileater_nxd) and mail (pdm_mail_nxd) processes