Notifier Setup Tab

A notifier is defined as the target where event messages are sent. A notifier may output information to Azure Application Insight, any type of database table, log file, SNMP trap, Mail, SNS topic, or the standard System Log.

Event Notification - Notifier Setup tab

Setting

Description

Setting

Description

Notification Type

Select the output type for the notification in this drop-down list. See the detailed descriptions of the notification types in the section below, Notification Type Configuration.

Duplicate Suppression (sec)

Enter the number of seconds during which an identical event is suppressed from being logged. The default value is 0.

Base Configuration

The Base Configuration settings vary depending on the selected notification type and can be the location of a log file, database profile, or credentials, etc. See the respective notification type descriptions below for more information.

Target Field Configuration

These settings are used for constructing the content of the notification, and they vary depending on which notification type you have selected, see information about each notification type below.

Notification Type Configuration

The event notification types that you can configure are:

  • Azure Application Insight

  • Database

  • Log File

  • Send Mail

  • Send SNMP Trap

  • Send SNMP Trap, Alarm

  • SNS Topic

  • System Log

Azure Application Insight

Database

When you select the Database notification type, Event fields can be inserted into database tables using either plain SQL statements or calls to stored procedures.

Event Notification - Notification Type Database

Setting

Description

Setting

Description

Database

Browse and select the database profile defining the database in which the table resides, see Database Profile for information about how to define a Database profile. 

SQL Statement

Type in any SQL statement, using '?' for variables which are to be mapped against event fields in the Event Setup tab. Trailing semicolons are not used. In the case of running several statements, they must be embedded in a block.

Log File

When you select the Log File notification type, messages can be routed to ordinary text files on the local file system.

 
Event Notification - Notification Type Log File

Setting

Description

Setting

Description

Directory

Enter the path to the directory where the file in which events are to be logged resides.

Filename

Enter the name of the file in which events are to be logged. In case the file does not exist, it will be created when the first message for the specific event map arrives. New messages are appended.

Size

Select this check box to define the maximum size of the file. When this parameter is exceeded, the existing file is renamed and a new one is created upon the arrival of the next event.

The old file will receive an extension to the file name, according to <date_time_milliseconds_timezone>.

Time

Select this check box to define the maximum lifetime of a file before it is rotated. When this parameter is exceeded, the existing file is renamed and a new is created upon the arrival of the next event.

If the time is set to rotate every:

  • hour, rotation is made at the first full-hour shift which is xx:59.

  • 2 hours, rotation is made in predefined two-hour intervals (0,2,4...22) when turning to the next full hour. For example after 01:59.

  • 3 hours, rotation is made in predefined three-hour intervals (0,3,6, ...21) when turning to the next full hour. For example after 02:59.

  • 4 hours, rotation is made in predefined four-hour intervals (0,4,8, ...20) when turning to the next full hour. For example after 03:59.

  • 6 hours, rotation is made in predefined six-hour intervals (0,6,12 ...21) when turning to the next full hour. For example after 05:59.

  • 8 hours, rotation is made in predefined eight-hour intervals (0,8,16) when turning to the next full hour. For example after 07:59.

  • 12 hours, rotation is made at high noon and at midnight.

  • day, rotation is made at midnight.

  • week, rotation will be done at midnight on the last day of the week.

  • month, the rotation will be done at midnight on the last day of the month.

The old file will receive an extension to the file name, according to <date_time_milliseconds_timezone>.

If both Size and Time are set, both behaviors apply.

Separator

Select how to separate logged events from each other. Valid options are:

  • Linefeed

  • CR + LF (Carriage return + Linefeed)

  • Comma

  • Colon

  • (None)

Log Line

Enter the text to go into the log file.

For further information about how to obtain the text, see Target Field Configuration below.

Note!

Do not configure two different Event Notifiers to log information to the same file. Messages may be lost since only one notifier at a time can write to a file. Define one Event Notifier with several Event Setups instead.

Send Mail

When you select the Send Mail notification type, emails can be sent to one or several recipients when the specified events occur. Make sure the correct mail parameters have been configured in the platform.conf. You must enter a value for the property mz.notifier.mailfrom, see Platform Properties for more information about the mail properties.

Setting

Description

Setting

Description

Sender

Enter a label or name to be displayed in the Sender of the mail. The text in the Sender field will not replace the value of the platform.conf property that is set in mz.notifier.mailfrom.

For further information about how to obtain the text, see Target Field Configuration below.

Recipient

Enter the mail address(es) to one or several recipients. Use a comma to separate, if several. Click on the Add... button to select mail addresses, configured for available users.

For further information about how to obtain the text, see Target Field Configuration below.

Subject

Enter the subject/heading of the mail. If Event Contents is selected, newlines will be replaced with spaces to make the subject readable. If the string exceeds 100 characters, it is truncated.

For further information about how to obtain the text, see Target Field Configuration below.

Message

Enter the body of the mail message.

For further information about how to obtain the text, see Target Field Configuration below.

Send SNMP Trap

When you select the Send SNMP Trap notification type, events may be sent in the form of SNMP traps to systems configured to receive such information. For the MIB definition, see the $MZ_HOME/etc/mz_trap_mib.txt file.

Note!

A new SNMP trap format is now available. For backward compatibility purposes, the previous invalid format will still be used by default. However, if you want to use the new format you can add the property

snmp.trap.format.b

to the platform.conf and set it to true to activate the new values.

You can use the topo command to set the property snmp.trap.format.b:

$ mzsh topo set topo://container:<container>/pico:platform/val:config.properties.snmp.trap.format.b true


The value of the agent Address field will be taken from the Container property  pico.rcp.server.host .

 
Event Notification - Notification Type Send SNMP Trap

Setting

Description

Setting

Description

IP Address

Enter the IP address of the target host.

Port

Enter the port on the target host defined for the SNMP communication.

Community

Enter the community name string used for the authentication process.

Version

Select which SNMP version to use in this drop-down list containing all supported versions.

User Message

Enter a string to be sent out as SNMP traps.

For further information about how to obtain the text, see Target Field Configuration below.

Send SNMP Trap, Alarm

When you select the Send SNMP Trap Alarm notification type, you can create a notification type that is similar to the Send SNMP Trap notification type, with one difference; It is specifically designed to work for Alarm events.

 
Event Notification - Notification Type Send SNMP Trap Alarm

Setting

Description

Setting

Description

IP Address

Enter the IP address of the target host.

Port

Enter the port on the target host defined for the SNMP communication.

Community

Enter the community name string used for the authentication process.

Version

Select which SNMP version to use in this drop-down list containing all supported versions.

Target Field Configuration alarm*

Configure the content for each field in the alarms. 

For further information about how to obtain the text, see Target Field Configuration below.

SNS Topic

When you select the SNS Topic notification type, messages produced by the selected events are routed as SNS topics to the specified Amazon S3 region.

Setting

Description

Setting

Description

Access Key

Enter the access key for the user who owns the Amazon S3 account in this field.

Secret Key

Enter the secret key for the stated access key in this field.

Region

Enter the name of the Amazon S3 region in this field.

Topic

Configure the SNS topic.

For further information about how to obtain the text, see Target Field Configuration below.

Message

Enter the body of the topic.

For further information about how to obtain the text, see Target Field Configuration below.

System Log

When you select the System Log notification type, messages produced by the selected events are sent to the standard System Log. The Contents field from each event is used as the message in the log.

 
Event Notification - Notification Type System Log

Note!

Do not route frequent events to the System Log. Purging a large log might turn into a performance issue. If still doing that, keep the log size at a reasonable level by applying the System Task System Log Cleaner. For further details see System Log Cleaner in Workflow Types.

Target Field Configuration

Some of the notifier types have one or many parameters that may be dynamically populated by data from an event. These parameters are configured in the Target Field Configuration section.

Depending on the parameter type, there will be one or several population types available in the list next to it.

Manual

Select Manual to hard code a value, and thus give no possibility to select any dynamic values to be embedded in the message. The value entered will be assigned to the parameter exactly as typed.

 
Target Field Configuration - Log Line

Event Field

Select Event Field to assign the value of one specific event field. The event fields for the added events can be viewed in the Event Setup Tab.

For further information about fields valid for selection, see Event Fields.

Event Contents

Select Event Contents to add the event value of each event's Contents field. All event types have suitable event content text. For example, in the figure Events can be customized to suit any target, the Event Contents string will be:

Username: mzadmin3, Action: Notifier AnumberEvents updated.

Another example is that the following string is reported for a User Defined Event:

Workflow name: <name>, Agent name: <name>, Message: <string>

The Message string originates from the dispatchMessage function. Note that nothing will be logged unless dispatchMessage is used. Also, in this case, the Field Maps in the Event Setup will be disabled.

Formatted

Select Formatted to enter text combined with variable names, which are assigned to event field values in the Event Setup Tab tab.

 

Each variable in Notifier Setup has its own Notifier Field in Event Setup - Send Mail

For each variable entered in a field with the Formatted option selected, a notifier field will be added in the Event Setup tab where you can then assign event field values.

Variable names must be preceded by a $, started with a letter, and be comprised of a sequence of letters, digits, or underscores.

 

Target Field Configuration - Log Line

The settings in the screenshot above will be interpreted as containing the variables 'NO' and 'ANUM'.