Bug 1252136 - Initial drift definition snapshot is not taken and breaks drift
Initial drift definition snapshot is not taken and breaks drift
Status: CLOSED ERRATA
Product: JBoss Operations Network
Classification: JBoss
Component: Drift (Show other bugs)
JON 3.3.3
Unspecified Unspecified
urgent Severity urgent
: ER01
: JON 3.3.4
Assigned To: Libor Zoubek
Filip Brychta
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-08-10 15:22 EDT by dsteigne
Modified: 2015-11-01 19:44 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-10-28 10:37:12 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Screenshot of drift (154.64 KB, image/png)
2015-08-10 15:26 EDT, dsteigne
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 1566643 None None None Never

  None (edit)
Description dsteigne 2015-08-10 15:22:29 EDT
Description of problem:
Initial drift definition snapshot is not taken and shows 'None' under Snapshot Definition page.

Version-Release number of selected component (if applicable):
3.3.0, 3.3.3

How reproducible:
Always

Steps to Reproduce:
1.Create a new Drift Definition on an EAP 6 Standalone Server, with Template-Configuration Files, add the standalone.xml to the Includes list, set the scan interval to 90 seconds, Save.  The initial snapshot is taken and shows 0 in the Snapshot column.
2. Stop that EAP server, make a change to the standalone.xml file, i.e. change the server name - <server name="testserver2" xmlns="urn:jboss:domain:1.1"> and restart it.
3. Hit refresh after 2 minutes to see the new snapshot on the Drift Definition. 
4. Create another Drift Definition on the same EAP6 Standalone Server, with same template and include the standalone-ha.xml or any file from the configDir, Save. The initial snapshot is NOT taken and shows 'None' in the snapshot column.(attached screenshot)
5. Stop that EAP server, make another change to the standalone.xml file, i.e. change the server name - <server name="testserver3" xmlns="urn:jboss:domain:1.1"> and restart it.
6. Hit refresh after 2 minutes, no snapshots are taken for either Drift Definition. 
7. Create a new Drift Definition on another resource under that same agent, you will see the same as in Step 4.
Actual results:
Initial snapshot is only taken for the First Drift definition on the entire agent and drift is broken if more than that one definition is created.

Expected results:
Every Drift Definition would have the initial snapshot taken and not break Drift.

Additional info:
Comment 1 dsteigne 2015-08-10 15:26:44 EDT
Created attachment 1061194 [details]
Screenshot of drift
Comment 4 Libor Zoubek 2015-09-02 08:54:28 EDT
branch:  master
link:    https://github.com/rhq-project/rhq/commit/d22799150
time:    2015-09-02 14:47:26 +0200
commit:  d22799150dea99626c4e7fb2c2d02f6845ac1e03
author:  Libor Zoubek - lzoubek@redhat.com
message: Bug 1252136 - Initial drift definition snapshot is not taken and breaks 
         drift
         Fixed DriftDetectionSchedule comparator. It caused that
         schedules with higher nextCheckInterval were inserted to the
         beginning of the priority queue, but DriftDetector relies on
         lowest checkInterval. As a result only one drift detection
         schedule could ever run on agent.
Comment 5 Michael Burman 2015-09-25 03:40:45 EDT
Cherry-picked to release/jon3.3.x:

commit 43e1e395864ab695fa95c32a76007ebfca8493c7
Author: Libor Zoubek <lzoubek@redhat.com>
Date:   Wed Sep 2 14:47:26 2015 +0200

    Bug 1252136 - Initial drift definition snapshot is not taken and breaks
    drift
    
    Fixed DriftDetectionSchedule comparator. It caused that schedules with
    higher nextCheckInterval were inserted to the beginning of the priority
    queue, but DriftDetector relies on lowest checkInterval. As a result only
    one drift detection schedule could ever run on agent.
    
    (cherry picked from commit d22799150dea99626c4e7fb2c2d02f6845ac1e03)
Comment 6 Michael Burman 2015-09-28 06:11:55 EDT
Fixing the test:

On master:

commit 7c32f5ef5d5cecc0861a2a85e0299604c6088ec4
Author: Michael Burman <miburman@redhat.com>
Date:   Mon Sep 28 13:09:14 2015 +0300

    [BZ 1252136] Fix the regression test to follow what it should do instead of what the feature was doing..

On release/jon3.3.x:

commit c43ed54d1f446da28437361c80ae674076eb03be
Author: Michael Burman <miburman@redhat.com>
Date:   Mon Sep 28 13:09:14 2015 +0300

    [BZ 1252136] Fix the regression test to follow what it should do instead of what the feature was doing..
    
    (cherry picked from commit 7c32f5ef5d5cecc0861a2a85e0299604c6088ec4)
Comment 7 Simeon Pinder 2015-10-09 00:40:16 EDT
Moving to ON_QA as available to test with the following build:
https://brewweb.devel.redhat.com/buildinfo?buildID=460382

 *Note: jon-server-patch-3.3.0.GA.zip maps to ER01 build of
 jon-server-3.3.0.GA-update-04.zip.
Comment 8 Filip Brychta 2015-10-09 08:45:31 EDT
Verified on
Version :	
3.3.0.GA Update 04
Build Number :	
821a526:fa7b1a1
Comment 10 errata-xmlrpc 2015-10-28 10:37:12 EDT
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://rhn.redhat.com/errata/RHSA-2015-1947.html

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