Bug 1575920

Summary: When an alert template is applied to a message containing Russian characters (which are properly shown in the JBoss ON UI), they will be replaced in the received email with the "?" characters
Product: [JBoss] JBoss Operations Network Reporter: bkramer <bkramer>
Component: Core ServerAssignee: Michael Burman <miburman>
Status: CLOSED ERRATA QA Contact: Sunil Kondkar <skondkar>
Severity: medium Docs Contact:
Priority: medium    
Version: JON 3.3.10CC: fbrychta, skondkar, spinder
Target Milestone: ER01Keywords: Triaged
Target Release: JON 3.3.11   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-10-16 17:07:04 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description bkramer 2018-05-08 09:55:03 UTC
Description of problem:
When an alert template is applied to a message containing Russian characters (which are properly shown in the JBoss ON UI), they will be replaced in the received email with the "?" characters.

Version-Release number of selected component (if applicable):
3.3 (reproduced with 3.3.0 and 3.3.10)

How reproducible:
Always

Steps to Reproduce:
1. A resource is configured to collect events where some of the collected messages contain Russian characters - for an example - see attached log file;
2. Create an alert that is triggered when Event - INFO is collected and choose email as a notification;
3. Copy the message from the provided log file and add it as a new message to the same log file;
4. Save the change and execute "sync" on the terminal;
5. Navigate to the JBoss ON UI and confirm that newly added message is shown in the list of Events;
6. Navigate to the alert history page for the same resource and confirm that new alert has been triggered;
7. Check the Inbox for the new email from the JBoss ON

Actual results:
Newly received email will contain "?" characters;

Expected results:
Newly received email contains Russian characters as shown in the JBoss ON UI;


Additional info:
When the same message is sent from the JBoss ON UI Test Email page (http://<jon_server_ip_address>:7080/coregui/#Test/ServerAccess/EmailTest) received email is correct (no "?" characters). Unfortunately, we cannot use "Use Alert Template" check box for this as the template will be applied to the default text:

******************************************
Subject: [ALERT] priority of [!!! - High] for alert [Test Alert Name] on resource [Test Resource Name]

The resource Test Resource Name has generated the following alert:

------------------------------------------

Resource Name    : Test Resource Name
Alert Name       : Test Alert Name
Alert Severity   : !!! - High
Alert Date/Time  : Jan 1, 1970
Conditions: Test Conditions

------------------------------------------

Resource Ancestry:

Test Resource Hierarchy

------------------------------------------

For additional details about this alert, go to http://localhost:7080

This message was delivered to you by RHQ.

******************************************

Comment 3 Michael Burman 2018-05-29 14:58:07 UTC
Fixed in the master:

commit 138495dae8e06223e824e5bd49e88f772c003c3e (HEAD -> master, upstream/master)
Author: Michael Burman <miburman>
Date:   Tue May 29 17:57:37 2018 +0300

    [BZ 1575920] Change charset of the email mime body to UTF-8

Comment 6 Sunil Kondkar 2018-09-21 14:00:25 UTC
Verified on Version :3.3.0.GA Update 11
Build Number :	669c61c:7f77b51

Verified that received email contains Russian characters.

Comment 8 errata-xmlrpc 2018-10-16 17:07:04 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2018:2930