Bug 1252136 - Initial drift definition snapshot is not taken and breaks drift
Summary: Initial drift definition snapshot is not taken and breaks drift
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: JBoss Operations Network
Classification: JBoss
Component: Drift
Version: JON 3.3.3
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: ER01
: JON 3.3.4
Assignee: Libor Zoubek
QA Contact: Filip Brychta
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-08-10 19:22 UTC by dsteigne
Modified: 2019-07-11 09:47 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-10-28 14:37:12 UTC
Type: Bug
Embargoed:


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


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 1566643 0 None None None Never
Red Hat Product Errata RHSA-2015:1947 0 normal SHIPPED_LIVE Important: Red Hat JBoss Operations Network 3.3.4 update 2015-10-28 18:36:15 UTC

Description dsteigne 2015-08-10 19:22:29 UTC
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 19:26:44 UTC
Created attachment 1061194 [details]
Screenshot of drift

Comment 4 Libor Zoubek 2015-09-02 12:54:28 UTC
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
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 07:40:45 UTC
Cherry-picked to release/jon3.3.x:

commit 43e1e395864ab695fa95c32a76007ebfca8493c7
Author: Libor Zoubek <lzoubek>
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 10:11:55 UTC
Fixing the test:

On master:

commit 7c32f5ef5d5cecc0861a2a85e0299604c6088ec4
Author: Michael Burman <miburman>
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>
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 04:40:16 UTC
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 12:45:31 UTC
Verified on
Version :	
3.3.0.GA Update 04
Build Number :	
821a526:fa7b1a1

Comment 10 errata-xmlrpc 2015-10-28 14:37:12 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://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.