Saviynt unveils its cutting-edge Intelligence Suite products to revolutionize Identity Security!
Click HERE to see how Saviynt Intelligence is transforming the industry.
Saviynt Copilot Icon

Analytics variables suddenly not working/ Email triggers failing

sb17gds
New Contributor III
New Contributor III

Hi,

Has someone ever encountered a case where analytics variables suddenly stop working?

Up until a few hours ago, when I was running analytics report, emails that had analytics variables in them were triggering. But now they are triggering only when I remove all variables. 

There has been no change in email templates, nor has there been any change in report. 

Checked logs, but it appears something is running through all users as all entries look like this:

"2024-10-25T12:14:30.134+00:00","ecm","services.WorkflowService","http-nio-8080-exec-7-8ncwz","DEBUG","checking for 59594"
"2024-10-25T12:14:30.134+00:00","ecm","services.WorkflowService","http-nio-8080-exec-7-8ncwz","DEBUG","checking for 59595"
"2024-10-25T12:14:30.134+00:00","ecm","services.WorkflowService","http-nio-8080-exec-7-8ncwz","DEBUG","checking for 59596"
"2024-10-25T12:14:30.135+00:00","ecm","services.WorkflowService","http-nio-8080-exec-7-8ncwz","DEBUG","checking for 59597"

so on and so forth.

Just for reference, though, email template:

sb17gds_0-1729859116319.png

 

Report:

select 'admin' as 'USERNAME', u.email as 'EMAIL', u.employeeid as 'USEREMPLOYEEID', a.username as 'MANAGER', u.firstname as 'FIRSTNAME', u.lastname as 'LASTNAME', a.firstname as 'MFIRSTNAME', a.lastname as 'MLASTNAME', u.termdate as 'TERMDATE', SUBSTRING_INDEX(SUBSTRING_INDEX(SUBSTRING_INDEX(SUBSTRING_INDEX(u.comments, '[', -1), ']', 1), '- ', -1), '-', 1) AS
'UCOMMENTS', u.comments as 'UCOMMENTS1' from users u, users a where u.manager = a.userkey and u.statuskey = 0 and u.comments like '%Certification%' and u.termdate >= NOW() - INTERVAL 7 DAY

10 REPLIES 10

sb17gds
New Contributor III
New Contributor III

Found this line in logs:

groovy.lang.MissingPropertyException: No such property: Certifier_FName for class: java.lang.String at SimpleTemplateScript86.run(SimpleTemplateScript86.groovy:1) at com.saviynt.ecm.analytics.AnalyticsESService$_notifyEmailToOwner_closure39.doCall(AnalyticsESService.groovy:2554) at com.saviynt.ecm.analytics.AnalyticsESService.notifyEmailToOwner(AnalyticsESService.groovy:2539) at com.saviynt.ecm.analytics.AnalyticsESService.emailAction(AnalyticsESService.groovy:16541) at com.saviynt.ecm.analytics.AnalyticsESService.doFileArchivalAndSendEmail(AnalyticsESService.groovy:14717) at com.saviynt.ecm.analytics.AnalyticsESService$_runControl_closure210_closure318.doCall(AnalyticsESService.groovy:14550) at com.saviynt.ecm.analytics.AnalyticsESService$_runControl_closure210.doCall(AnalyticsESService.groovy:14549) at java.lang.Thread.run(Thread.java:750)

When I tried running another report with this variable name in it. Report ran but no emails as soon as i added the variable  ${ANALYTICSDATA.Certifier_FName[0]}

rushikeshvartak
All-Star
All-Star

It seems you have tagged another email template to analytics. please validate


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

Email and report match

sb17gds_0-1729861370829.pngsb17gds_1-1729861412429.png

 

Just use below code in mail body and validate

Please validate supported variables.

Purpose :

To get what variables are present to use in the email template.

Email Template steps :

keep Advanced HTML CSS flag is checked

Keep your email Address in TO

TO /CC/BCC & Subject - Don't use any dynamic variables

Add only below code in Email Body
${this.binding.variables.each {RVkey,RVvalue -> println "$RVkey ------- $RVvalue" + "" + "br" + ">"}}

Output : using the below expression. By putting it in the email body, it will print all variable names with values, and then accordingly, you can use it:


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

sent this to my mail once i ran the report

date ------- 2024-10-25 13:16:44br> endpoint ------- nullbr> totalRecords ------- 3br> analyticsConfig ------- com.saviynt.ecm.analytics.AnalyticsConfigES : 939br> endpointDisplayName ------- nullbr> baseUrlForEmail ------- https://hostname.saviyntcloud.com/ECMbr> ownerEmail ------- br> out ------- java.io.PrintWriter@57b5fc7br> [date:2024-10-25 13:16:44, endpoint:null, totalRecords:3, analyticsConfig:com.saviynt.ecm.analytics.AnalyticsConfigES : 939, endpointDisplayName:null, baseUrlForEmail:https://hostname.saviyntcloud.com/ECM, ownerEmail:, out:java.io.PrintWriter@57b5fc7]

This was the report query:

select 'admin' as 'USERNAME', u.email as 'EMAIL', u.employeeid as 'USEREMPLOYEEID', a.username as 'MANAGER', u.firstname as 'FIRSTNAME', u.lastname as 'LASTNAME', a.firstname as 'MFIRSTNAME', a.lastname as 'MLASTNAME', u.termdate as 'TERMDATE', SUBSTRING_INDEX(SUBSTRING_INDEX(SUBSTRING_INDEX(SUBSTRING_INDEX(u.comments, '[', -1), ']', 1), '- ', -1), '-', 1) AS
'UCOMMENTS', u.comments as 'UCOMMENTS1' from users u, users a where u.manager = a.userkey and u.statuskey = 0 and u.comments like '%Certification%' and u.termdate >= NOW() - INTERVAL 7 DAY

Is there something i have to do?

It seems you are showing 2 issues/report one time. Does global configuration group by username is enabled ?


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

No it is not enabled. That's why when i run any report without any variables, it sends me the number of mails that are entries in analytics, with separate user in excel sheet of each mail. But as soon as i add a variable, it stops triggering.

I should also note that this was working just a couple hours ago, no worries.

As option is not enabled and variable is not exposed in email template


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

For this report share screenshot of config for report and email


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

sb17gds
New Contributor III
New Contributor III

But the option was never enabled from the start. Also, if i enabled it, wouldnt it only send one email per username that is admin?

I need it to send separate emails with separate user info