Notifications#
In this article we describe the notifications module, which has the purpose to check various data in the IT documentation and to send emails in the case of specific events. The module consists of particular kinds of notifications, the setup of these notification types, e-mail templates and last but not least the regular execution of the controller.
Kinds of Notifications#
You can carry out the configuration settings at Extras → Notifications. Currently, you can choose from the following kinds of notifications:
Notification | Description |
---|---|
Changed objects | Checks objects which have been changed in a custom-defined time frame. As an example, a daily list of all objects that have been changed in the last 24 hours can be issued. |
CMDB status ends | Helpful for the category "status planning". This notifications informs you about a planned CMDB status that is going to end. |
CMDB status started | Helpful for the category "status planning". This notification informs you about a planned CMDB status that is going to start. |
Expiration of a certification period | Checks all object types associated to the category "certificate" for the expiration date of the certificate. |
Expiration of a notice period | Checks contracts for the time frame until the expiration of the notice period. |
Free licenses | Checks licenses for the number of available licenses left. |
i-doit update | Checks whether a new version of i-doit is available. i-doit requires an internet connection to do so. |
License expiration | Checks licenses for the time frame until they expire. To avoid being notified of expired licenses, the Skip expired licenses option must be set to Yes . |
Report based notification | Executes reports and notifies you once a custom number of found objects is reached. |
Stored objects | Checks any object type for the number of contained objects with the status "stored". |
Unchanged objects | Checks objects which have not been changed in a custom-defined time frame. Can be helpful to find very old data and update them in processes. |
Expiration of a maintenance/guarantee period | Checks contracts for the time frame until the expiration of the maintenance/ guarantee period. |
The "Report based notification" can be used in a very flexible way and can send appropriate notifications for almost all events and statuses.
Setup#
The setup of notifications always follows the same pattern. General settings, like a threshold value, a limit of notifications, objects which will be monitored and contacts that are to be notified, are defined.
Common Settings#
Notification | Description |
---|---|
Title | The Title should be meaningful at best. |
Active | The checkbox can be clicked here for activation. Notifications can be deactivated. |
Threshold | The threshold value varies depending on whether a time factor (X years/months/days/hours/minutes/seconds) or a counter (number of objects found) can be set for the notification. Above the settings, there is a brief explanation of the notification and information on what is checked with the threshold value. |
max. Amount of notifications to be sent | If the notification is checked several times and an object is found several times, a limit can be set here after which no further notifications are sent. Anything less than 0 means that notifications are sent until the objects have been changed and the notification is no longer valid. Beispiel: If the system checks and notifies every day and a 5 is entered in the field, no further notifications are sent after 5 days. If the object is updated in the meantime or after the maximum number of notifications so that it can no longer be found via the notification, the counter is reset to 0 |
Amount of sent notifications | The display shown here is purely informative and is either increased with each run if a notification has been sent or reset if none has been sent. |
Date of last run | Also purely informative. Shows when the last time was checked. |
Interval start date | A date can be selected in this field, the date is the start date for the interval. |
Start date of the interval | A date can be selected in this field; the date is the start date for the interval. |
Interval configuration | This field is used to configure the interval, if no interval is set, this is shown in the field with "No interval defined". Intervals can be repeated e.g. daily or weekly etc. The end of the interval can also be configured. |
English template | The selected template is used for notifications in English. |
German template | The selected template is used for notifications in German. |
Description | This field is a free text field for a description of the notification. |
Domains#
Objects which are to be checked by the notification can be selected specifically or according to a pattern in the domains.
Setting | Description |
---|---|
Objects | One or more objects can be selected via the magnifier. |
Object types | All objects of one or more selected object types can be checked here. |
Reports | Notifications can be even more specific with a report. Example: The aim is to test whether enough free licenses are left which cost more than 150 EUR per license since a longer process applies here compared to the cheaper licenses. Then a second report can be created and used in another notification in order to query the cheaper licences and to effect a notification at a later time. Please be really mindful of the domain and the queried categories assigned to the object types! |
Depending on the notification, only certain object types are supported. For example, only objects of type "Contract" may be specified when checking contracts and only objects of type "License" when checking licenses.
Receivers#
You can also notify recipients both specifically or collectively.
Setting | Description |
---|---|
Assigned roles | When an object is found with the configured notification, you can notify the contact which is assigned to the object in the role that is set here. Example: The documented contact with the role "Contract partner" can be notified via the category "Contact assignment" in the contract. |
Assigned contacts | It is also possible to notify one or more contacts/ person groups or organizations. Important for this is a defined email address for each contact object. |
Receiver calculation strategy | Used calculation strategy of recipients when resolving Person groups to persons. This setting affects only groups of persons assigned as contacts. |
Receiver calculation strategy | Description |
---|---|
- | This is the default = Groups if available, otherwise assigned persons |
Groups and Persons | The primary email address of the Person group and each Person group member are notified. |
Groups if available, otherwise assigned persons | If the person group has stored a primary e-mail address, this will be notified. If the person group does NOT have a primary e-mail address, the primary e-mail address of each person group member will be notified. |
Groups only | Person groups with a primary email address will be notified. |
Persons only | Person group member with a primary email address will be notified. |
E-mail Templates#
The templates matching the corresponding notifications can be selected and adjusted for the German or English language in the left navigation tree. This always applies globally to all users and because of this your adjustments should not be be too specific. There is no possibility to reset the template to default. Whether the German or the English message is sent depends on the user settings of the contact who will be notified. If this user was never logged in to i-doit, the default language of i-doit is used for the notification.
Setting | Description |
---|---|
Language | The language that is currently being edited is displayed. |
Subject | The subject of the message can be customized with placeholders from the bottom section of the interface. |
Notification text | The text can be assembled with placeholders just like the subject. |
Report | A report for the e-mail can be defined here, which is then used to organize the object information found in the notification. |
Configuration of the call with the CLI#
To ensure that the set-up notifications are also checked regularly, the i-doit CLI must be executed with the command notifications-send, for example as a cron job. It is not possible to call up each notification individually, but all notifications are always checked automatically one after the other. It makes sense to consider how often the maximum number of checks should be. In our experience, it has proven useful to check every day shortly before starting work, so that it is immediately clear in the morning what you should deal with during the day.
Without a call of the command via the i-doit CLI no dispatch of the notifications takes place!
The possible parameters as well as an example call for sending notifications can be found in the corresponding article for the command notifications-send.
You can map escalation levels by using the notification module. For this, you need to set up multiple notifications with different recipient groups and threshold values for the same notification types.
Example of use
1 |
|
Logging#
When the CLI command notifications-send is called, a log file is created. The file with the name notifications_YYYY-MM-DD.log
can be found in the i-doit log
folder. If a person is not notified, the reason can be found in the log file.