Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The Handler Configuration paves the way for configuring Alerts, Custom Handler and Audit

  1. Click Handler Configuration drop-down list and three different segments namely, Alerts, Custom Handler and Audit appear.

Image Removed

Alerts

Alerts can be of much significance to the users. Ranging from login activities to request approvals, events can help you to keep track of the alerts in a smooth and convenient way. To configure Alerts, perform the following steps.

  1. Click Image Removed icon to configure Alerts.

Image Removed
The New Alert page appears.
Image Removed
The Alert ID gets assigned automatically.

  1. If you wish to change the Alert ID, type the numbers of your choice.
  2. Click the Severity drop-down list to choose the level of severity.
  3. If you want to assign a new datasource, then enter a relevant value in the Datasource text field, e.g. com.intellectdesign.modelhouse.alert.handler.NotificationAlertDataSource.

Note: The aforementioned datasource class needs to implement IAlertDataSource.

  1. Assigning the relevant datasource class facilitates the purpose of fetching the target recipients. It is not mandatory to enter a value in the field of Datasource. If the field is left blank, then the default datasource class will be taken into account.

Image Removed

  1. The Description gets assigned automatically. If you wish to modify the Description, then you can modify it. Select the Entitlement drop-down list and click SELF option. Based on the selected Entitlement, the alerts tend to differ for each and every type. Select the checkbox of Alert Enabled.

Image Removed

  1. If you wish to assign an engine class for the Entitlement Type, click Image Removed icon to configure Entitlements. A new pop-up appears. Type SELF in the text field of Entitlement Type and enter a relevant value in the text field of Engine Class, e.g. com.intellectdesign.modelhouse.alerts.EventEntitlementEngine. After entering the values, click Save to save the changes.

Image Removed
Channel Configuration determines the type of channel and the users can receive the alerts, through the means of the channel, which they prefer to choose. Inbox, SMTP, SMS and Push Notifications are the four available channels. Inbox indicates the messages that appear as notifications in the application. SMTP indicates electronic mails. SMS appears as a text message in mobile, whereas Push notifications serve the purpose, in the form of a mobile notification.

  1. In the section of Channel Configuration, click Channels drop-down list to select the channel of your choice, e.g. INBOX.

Image Removed

Inbox

  1. On selecting Inbox, you can find new set of options like Insert Key, Template Formatter, Language, Short Message/Subject, Select Header/Footer Template and Detailed Message.

Image Removed

  1. Click the drop-down list of Template Formatter and you can choose any one of the options from FreeMarker or Canvas – Default.

Image Removed

  1. Type the words of your choice in the field of Short Message/Subject. Click Image Removed icon to choose header or footer template in the field of Select Header/Footer Template. If you don't wish to choose a template for Header and Footer, then you can proceed further. The Insert Key drop-down list comprises of various keys. While entering the text in Detailed Message, make sure that you use Insert Key drop-down list in accordance with the assigning of alerts. For instance, if request approval is involved, then APPROVER_NAME can be used for more significance.

Image Removed

  1. You can even allot multiple Insert Keys, while typing the words of your choice in Detailed Message text field. The following screen shot showcases the usage of a second Insert Key, known as APPROVER_ID.

Image Removed

  1. After typing the words of your choice in the text field of Detailed Message, click Add.

Image Removed
The newly created alert appears on the right side, in the form of channel number; which denotes the channel type, e.g. 2001 denotes Inbox.
Image Removed

SMTP

  1. To create alerts for SMTP, click Channels drop-down list and select the option of 2002-SMTP.

Image Removed

  1. Select either Canvas – Default or FreeMarker from Template Formatter drop-down list. Enter the words of your choice in the text fields of Short Message/Subject and Detailed Message. While entering the text in Detailed Message, make sure that you use Insert Key drop-down list in accordance with the assigning of alerts. Once you have completed the proceedings, click Add.

Image Removed

SMS

  1. To create alerts for SMS, click Channels drop-down list and select the option of 2003-SMS.

Image Removed

  1. Select either Canvas – Default or FreeMarker from Template Formatter drop-down list. Enter the words of your choice in the text fields of Short Message/Subject and Detailed Message. While entering the text in Detailed Message, make sure that you use Insert Key drop-down list in accordance with the assigning of alerts. After completing the proceedings, click Add.

Image Removed

Push Notifications

  1. To create alerts for Push Notifications, click Channels drop-down list and select the option of 2004-PUSHNOTIF.

Image Removed

  1. Select either Canvas – Default or FreeMarker from Template Formatter drop-down list. Enter the words of your choice in the text fields of Short Message/Subject and Detailed Message. While entering the text in Detailed Message, make sure that you use Insert Key drop-down list in accordance with the assigning of alerts. After completing the proceedings, click Add.

Image Removed
The created alerts appear on the right side and the numbers denote the channel types (2001INBOX, 2002SMTP, 2003SMS, 2004PUSH NOTIFICATION).

  1. Click Save to save the created alerts.

Image Removed
The newly created Alert can be viewed in Alerts section under the segment of Handler Configuration. To edit the Alert, click Image Removed icon, whereas to delete it, click Image Removed icon.
Image Removed

Custom Handler

To configure Custom Handler, perform the following steps.

  1. Click Image Removed icon to configure Custom Handler.

Image Removed
Custom Handler Mapping page appears.
Image Removed

  1. Click the Handler drop-down list and select 10003-Cache Cleanup Handler.

Image Removed

  1. For other handlers, click Image Removed icon, adjacent to the Handler drop-down list.

Image Removed
A new pop-up appears.
Image Removed
The relevant values of the handlers can be found in the EVENT_HANDLER_MASTER_TABLE in Canvas Schema.

  1. Enter the relevant values in the fields of Handler ID, Handler Class, Handler Description and Priority. For Container ID, click Image Removed icon to select the form; that has been mapped to a container or enter the apt title of the Container ID. Based on the configuration of values, click the Y checkboxes of Ignore Exception and Is Synchronized? After completing the proceedings, click Create.

Image Removed

  1. If old values are required for the handler, click the Old Values Required checkbox.

Image Removed

  1. Click Save to save the changes.

Image Removed
The created Handler can be viewed in Custom Handler section under the segment of Handler Configuration. To edit the Custom Handler, click Image Removed icon, whereas to delete it, click Image Removed icon.
Image Removed

Audit

To configure Audit, perform the following steps.

  1. Click Image Removed icon to configure Audit.

Image Removed
The Audit page appears.
Image Removed

  1. The Audit ID is assigned automatically and you can modify it. Only numbers are permitted in the field of Audit ID. Enter the value, com.intellectdesign.canvas.audit.handler.AuditDataFormatter in Audit Formatter text field. Proceed to click Image Removed icon of Form ID to select a form.

Image Removed

  1. List of forms appear and you can select the form of your choice. For instance, NEW_PAYEE_FORM.

Image Removed

  1. Click Form Fields drop-down list.

Image Removed

  1. Click the form fields, which you wish to select. To perform a search, type the name of the form field in the Type to search field.

Image Removed

  1. After completing the proceedings, click Save to save the changes.

Image Removed
The newly created Audit can be viewed in Audit section under the segment of Handler Configuration. To edit Audit, click Image Removed icon, whereas to delete it, click Image Removed icon.
Image Removed

  1. In the Event page, click Submit.

Image Removed
A confirmation message, indicating a successful save appears.
Image Removed

  1. Click Ok.

Editing and Deleting Events

To edit and delete events, perform the following steps in Canvas Studio.

  1. On the home page of Canvas Studio, click Events on the left navigation pane.

Image Removed
The List of Events page appears.
Image Removed

  1. To edit an event, perform a right-click on the event and select Edit Event option.

Image Removed
The Event page appears. You can edit the fields which you want to edit, but Event ID remains as a non-editable field.
Image Removed

  1. To delete an event, perform a right-click on the event and select Delete Event option.

Image Removed

  1. Click Delete on the bottom right side of the Event Creation page.

Image Removed
A confirmation message appears, indicating a successful deletion.
Image Removed

Raising Events

After an event is configured in Canvas Studio, a simple Java handler is necessary to trigger the event. Let's assume that the event is a login activity, so when the user logs in, the event has to be raised to send an alert and an audit. Once the login event is configured in Canvas Studio, the Java Handler triggers the event, thereby facilitating the means for receiving alerts. The following code snippet is a sample Java Handler to raise an event:
Event eventToBeRaised = Event.getEventFor(<EVENT_ID>);  HashMap eventData = new HashMap();  EventDispatcher.getInstance().raiseEvent(eventToBeRaised , eventData);Image Added


For the full set of information on Handler Configuration, refer the following pages: 

  • Alerts
  • Custom Handler 
  • Audit