Error "Failure in datasource while processing FETCH request" when adding/viewing alert notification for resource groups or alert templates

Solution Verified - Updated

Environment

  • Red Hat JBoss Operations Network (ON)
    • 3.3.8
  • Viewing or adding a notification to the Notification panel for a Resource Group Alert Definition or Alert Definition Template

Issue

  • Error on creation of alert notification for resource groups or alert definition templates
  • Adding or viewing notifications for alerts on a group of resources or alert definition templates fails and the notification window spins endlessly
  • Attempt to add alert notification on the alert defined for resource group or in an alert definition template fails with the message Failure in datasource while processing FETCH request in the Message Center.

Resolution

This issue has been resolved in JBoss ON 3.3 Update-09 (3.3.9).

If you are not able to update, you can workaround the issue for Resource Group Alert Definitions by viewing and updating the Notifications within the group's individual resource's Alert Definition. For example, from the group's Inventory >> Members page, select a group member name and then view or modify its Alert Definition directly.

There is no known workaround for Alert Definition Templates.

Root Cause

The notifications panel in the user-interface (UI) is attempting to query the JBoss ON back-end database for a list of notifications using a resource ID. However, in the case of a Resource Group or Alert Definition Template no resource ID is associated with the alert notifications. This results in an empty list of notifications being returned by the database.

This is a regression in the UI due to the fix done for This content is not included.Red Hat Bugzilla 1382649 - Attempt to add notification for the second alert definition in UI throws message "Failed to get notification configuration preview".

Diagnostic Steps

Full error message reported in the JBoss ON Message Center is:

Message :	Failure in datasource while processing FETCH request.
Severity :	Error
Time :	        Monday, April 24, 2017 2:43:58 PM UTC+1
Root Cause :	(TypeError) : Cannot read property 'alertDefinitions' of null
Detail :	com.google.gwt.core.client.JavaScriptException:(TypeError) : Cannot read property 'alertDefinitions' of null
--- STACK TRACE FOLLOWS ---
(TypeError) : Cannot read property 'alertDefinitions' of null
   at Unknown.$getAlertDefinitions(<anonymous>@19)
   at Unknown.$prepareNotificationsForPreview(<anonymous>@5)
   at Unknown.$executeFetch_14(<anonymous>@12)
   at Unknown.executeFetch_19(<anonymous>@3)
   at Unknown.transformRequest_0(<anonymous>@14)
...

The below error message can also be shown:

Message :	Failure in datasource while processing FETCH request.
Severity :	Error
Time :	Thursday, April 27, 2017 11:54:36 AM UTC-5
Root Cause :	(TypeError) : this$static is null
Detail :	com.google.gwt.core.client.JavaScriptException:(TypeError) : this$static is null
--- STACK TRACE FOLLOWS ---
(TypeError) : this$static is null
   at Unknown.$getAlertDefinitions(Unknown Source)
   at Unknown.$prepareNotificationsForPreview(Unknown Source)
   at Unknown.$executeFetch_14(Unknown Source)
   at Unknown.executeFetch_19(Unknown Source)
   at Unknown.transformRequest_0(Unknown Source)
...
SBR
Category

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.