Bug 1200498

Summary: The output of rhq:audit is changed - Date is added to the "info"
Product: [Other] RHQ Project Reporter: bkramer <bkramer>
Component: ProvisioningAssignee: Nobody <nobody>
Status: ON_QA --- QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 4.12CC: hrupp
Target Milestone: ---   
Target Release: RHQ 4.14   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 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:
Bug Depends On:    
Bug Blocks: 1200493    
Attachments:
Description Flags
screen shot
none
example of the bundle none

Description bkramer 2015-03-10 16:47:19 UTC
Created attachment 1000065 [details]
screen shot

Description of problem:
In the bundles recipes events are logged like this:

<rhq:audit action="CONF_ITEM" info="PREINSTALL" message="My message - preinstall"></rhq:audit>			

In RHQ 4.9 the 'info' field has actual value as defined above (info=PREINSTALL).

In RHQ 4.12 a date is added at the end of info so info=PREINSTALLTue Mar 10 16:16:52 GMT 2015

Version-Release number of selected component (if applicable):
RHQ 4.12

How reproducible:
Always

Steps to Reproduce:
1. Install RHQ 4.12
2. Create a test group that contains "platform" resources (for instance);
3. Navigate to Bundles and upload a bundle whose recipe contains:
    <rhq:audit action="CONF_ITEM" info="PREINSTALL" message="My message - preinstall"></rhq:audit>
4. Deploy newly uploaded bundle to the resource group (created in step 2)  and define a deployment directory;
5. Navigate to bundle deployment and double click on status to open deployment history
6. Find "CONF_ITEM" action and check it's info

Actual results:
Info: PREINSTALLTue Mar 10 16:16:52 GMT 2015

Expected results:
Info: PREINSTALL

Additional info:
Added a screen shot that shows an issue and bundle example.

Comment 1 bkramer 2015-03-10 16:47:55 UTC
Created attachment 1000066 [details]
example of the bundle

Comment 2 Lukas Krejci 2015-03-10 17:29:55 UTC
This was accidentally introduced by BZ 1050014.

The changes for that BZ introduced what should have been a more optimal use of string builder to compose the message but actually caused its corruption due to incorrectly parenthesized statement.

The behavior prior to BZ 1050014 was to output the info or, if info was not set, to output "Timestamp: <current-time-and-date>" (where current-time-and-date was replaced by the actual current time and date at that instant).

After the accidental change the output was changed to info, or if info was not set, to "Timestamp: ". In both cases followed by the current time and date.

This is an unfortunate regression that splipped by QE.

Comment 3 Lukas Krejci 2015-03-10 17:40:20 UTC
commit 4c30284446bd9af845de82961479170f43964451
Author: Lukas Krejci <lkrejci>
Date:   Tue Mar 10 18:38:36 2015 +0100

    [BZ 1200498] Restore the format of ant bundle audit log message