Bug 738614 - Alert email received displays null in Conditions section
Summary: Alert email received displays null in Conditions section
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: RHQ Project
Classification: Other
Component: Core UI
Version: 4.1
Hardware: Unspecified
OS: Unspecified
medium
medium vote
Target Milestone: ---
: ---
Assignee: RHQ Project Maintainer
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks: jon30-bugs
TreeView+ depends on / blocked
 
Reported: 2011-09-15 11:38 UTC by Sunil Kondkar
Modified: 2012-02-07 19:23 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-02-07 19:23:22 UTC


Attachments (Terms of Use)
Alert Email Details (2.32 KB, application/octet-stream)
2011-09-15 11:40 UTC, Sunil Kondkar
no flags Details
Alert Email Details_2 (2.32 KB, text/plain)
2011-09-15 12:23 UTC, Sunil Kondkar
no flags Details

Description Sunil Kondkar 2011-09-15 11:38:43 UTC
Description of problem:

Created an alert on EJB3 Session Bean resource (Ex: AvailabilityManagerBean ) with below calltime alert conditions 

1. Call Time Value threshold [Method Invocation Time AVG < 50.0ms] 

2. Call Time Value Changes [Method Invocation Time AVG Changes by atleast 2.0% ]

When alert is fired, the email received displays 'null' in the 'Conditions' section as below:

1. Conditions: 
  - Condition 1: null < 50.0ms
  - Date/Time: 2011/09/15 15:25:46 IST
  - Details: [From:Sep 15, 2011 3:25:46 PM, To:Sep 15, 2011 3:56:32 PM, AVG:5.428571428571429], extraInfo=[updateLastAvailabilityReport]


2. Conditions: 
  - Condition 1: null value changed
  - Date/Time: 2011/09/15 15:25:46 IST
  - Details: [From:Sep 15, 2011 3:25:46 PM, To:Sep 15, 2011 3:56:32 PM, AVG:5.428571428571429], extraInfo=[updateLastAvailabilityReport]

Please refer the attached screenshot where i have pasted details of both the alert emails received.

Version-Release number of selected component (if applicable):
Build#411 (Version: 4.1.0-SNAPSHOT Build Number: 1a66725)

How reproducible:
Always

Steps to Reproduce:

1. Login to RHQ

2. Navigate to the 'RHQ Server->Applications->EJB3 Session Beans->AvailabilityManagerBean' resource.

3. Navigate to the 'Monitoring->Schedules' tab and enable and set collection interval for the metric 'Method Invocation Time' to 30 seconds.

4. Create an alert on the resource using below condition:

 Condition Type: 'Call Time Value threshold'
 Call Time Metric: 'method Invocation Time'
 Call Time Limit: Average
 Comparator: < (Less Than)
 Call Time Value: 50

5. Enter the email id in Notification tab using 'Direct Emails' option and save the alert definition.

6. Wait till the alert fires.

7. Observe the email received.
  
Actual results:

Alert email received displays null in Conditions section

Expected results:

Correct condition should be displayed in the alert email received.

Additional info:

Comment 1 Sunil Kondkar 2011-09-15 11:40:19 UTC
Created attachment 523360 [details]
Alert Email Details

Comment 2 John Mazzitelli 2011-09-15 12:17:34 UTC
what is this attachment? it has no extension and my system can't open it - just thinks its a raw binary file.

Comment 3 Sunil Kondkar 2011-09-15 12:23:29 UTC
Created attachment 523365 [details]
Alert Email Details_2

Comment 4 Sunil Kondkar 2011-09-15 12:25:16 UTC
Attached the text file for alert email details..

Comment 5 John Mazzitelli 2011-09-15 13:05:00 UTC
i'm pretty sure the code that needs to be fixed is in here:

org.rhq.enterprise.server.alert.AlertManagerBean.prettyPrintAlertCondition(AlertCondition, boolean)

Comment 6 John Mazzitelli 2011-09-16 02:59:37 UTC
sha commit eb50b72

Comment 7 Sunil Kondkar 2011-09-16 10:02:01 UTC
Verified on build#421 (Version: 4.1.0-SNAPSHOT Build Number: ad51846)

The Correct condition is displayed in the alert email received for both calltime alert conditions as below:


Conditions: 
  - Condition 1: Calltime Metric Method Invocation Time AVG < 50.0ms

Conditions: 
  - Condition 1: Calltime Metric Method Invocation Time AVG changes by at least 2.0%

Marking as verified.

Comment 8 Mike Foley 2012-02-07 19:23:22 UTC
changing status of VERIFIED BZs for JON 2.4.2 and JON 3.0 to CLOSED/CURRENTRELEASE


Note You need to log in before you can comment on or make changes to this bug.