Sending Email Alerts from TM1

There are many situations where you would like IBM TM1/Planning Analytics to send an email to the TM1 administrators or to TM1 users.

For example if a chore runs longer than expected, if some users are waiting or if the data does not reconciled.

IBM TM1/Planning Analytics does not include any tools to help you to send emails to your users. There are some workarounds but they are not very easy to set up.

You can overcome this by using Pulse for TM1, which is full of features that can help you in your day to day TM1 jobs, one of them is pro-active alerting. Pulse has lots of alert types that you can set-up such as memory alert, if the instance is offline and many more.

Use case: In most TM1 applications, chores run every night to load data, a chore can run successfully but it does not mean the data will reconcile. This article describes how Pulse can send you an email when the data between two cubes do not reconcile.

1. Write into the TM1 message log

From TM1 v10.2.2, a new function LogOutput has been included, it enables you to write to the tm1server.log from a TM1 process:

  • LogOutput('SeverityLevel', 'MessageString');

In the example below if the value is not the same between the General Ledger and Retail cubes, a message will be written the message log:

# Check Reconciliation
IF( nValueGL <> nValueRetail );
 message = 'Cost of Sales reconciliation failed between GL ( '| sValueGL | ' ) and Retail ( '| sValueRetail | ' ) for ' | cVersion | ' - ' | cYear ;
 LogOutput ('INFO', message);

2. Define an Alert in Pulse

In Pulse we would need to define a "Message in Log" alert. This will generate an alert every time a parameterized filter pattern is found in the tm1server.log.

For this example, we will set the filter  "*failed*" as the pattern to be detected by Pulse and a Notification Group (TM1Admin), in order to email those users that could be interested in receiving this notification.

You can also set this alert to be triggered by one instance or for all (leave instance blank), in this case, the alert will only applied for cxmd. 





Email Alert Sent

As a result, every time the TM1 process writes the “failure” message in the tm1server.log, Pulse will alert via email:

The email alert will report that the text pattern “failed”  has been found within the message log and will also include a snapshot of the instance’s TM1Top data: