Bug 758565 - Add drift templates to JBAS WAR/EAR resources
Summary: Add drift templates to JBAS WAR/EAR resources
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: RHQ Project
Classification: Other
Component: Plugins
Version: unspecified
Hardware: Unspecified
OS: Unspecified
high
unspecified
Target Milestone: ---
: RHQ 4.3.0,JON 3.0.0
Assignee: Jay Shaughnessy
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks: jon30-sprint9
TreeView+ depends on / blocked
 
Reported: 2011-11-30 04:31 UTC by Charles Crouch
Modified: 2015-02-01 23:27 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2012-02-07 19:22:24 UTC
Embargoed:


Attachments (Terms of Use)
a patch to re-apply the reverted commits and add back embedded WAR support (15.80 KB, patch)
2011-11-30 15:50 UTC, Jay Shaughnessy
no flags Details | Diff

Description Charles Crouch 2011-11-30 04:31:43 UTC
Drift template meta data should be added to the JBAS EAR/WAR resources types (via corresponding rhq-plugin.xml) so that users can create drift definitions on resources of those types.

Comment 1 Charles Crouch 2011-11-30 04:32:17 UTC
Unfortunately I did not create this bug ahead of time so Jay already has the fix committed into master:

http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=8c6dcd3817195f9a0f0d9855b3f7b648bd1ada5d
http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=0ad22b15a3f6d5b700bfec506db74f6a20633f21
http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=72d6aa5c440900dacaf8f97914ea2e17dea07112

Going forward we should reference this BZ when making commmits into any branch.

Comment 2 Charles Crouch 2011-11-30 04:42:48 UTC
As with other recent changes this should be tested in master and test cases documented here.
In order to minimize the amount of change associated with this issue, we should limit it purely to adding the drift template meta data to the appropriate rhq plugin descriptors. The implication of this is that drift on embedded webapps will not be explicitly supported, instead it will be available on the parent EAR resource. In order to ease testing master should be updated as follows:

1) Revert  http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=8c6dcd3817195f9a0f0d9855b3f7b648bd1ada5d, so that no plugin code changes are needed. 
2) Revert part of http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=0ad22b15a3f6d5b700bfec506db74f6a20633f21 so that no drift template metadata is specified for embedded web apps.
3) Revert part of http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=72d6aa5c440900dacaf8f97914ea2e17dea07112 so that no drift template metadata is specified for embedded web apps and no plugin code changes are needed.

The above changes are meant only to reduce the complexity of the current change. Long term the full fix should be pushed to master.

Comment 3 Jay Shaughnessy 2011-11-30 15:50:33 UTC
Created attachment 538615 [details]
a patch to re-apply the reverted commits and add back embedded WAR support

Comment 4 Jay Shaughnessy 2011-11-30 15:54:18 UTC
OK, reverted the three commits above and added new commit to just add
new templates to EAR/WAR for AS-4 and as-5.  Also, attached a patch 
to this bz that will re-apply the reverted commits when time comes to
add back the support for embedded WARs.

All in Master only:

commit 663c3c65527a5aacbcafead08614e4b416d52fa6

    After reverting the changes to support EAR/WAR/Embedded WAR
    types for AS-4 and AS-5 plugins, this now adds back drift
    templates for EAR and WAR types.  The Embedded WAR support will
    be added back in later, when the repo is open for the plugin
    code changes required to offer that support.

commit 42c78796a8b115058f4f87f2d9f61f1cdec11428

    This reverts commit 8c6dcd3817195f9a0f0d9855b3f7b648bd1ada5d.

commit a481dd1c53a035f9a633551ea982bc70d9e0188b

    This reverts commit 0ad22b15a3f6d5b700bfec506db74f6a20633f21.

commit aa79d1e533ca7a3e216719c933493d8ffef64b6b

    This reverts commit 72d6aa5c440900dacaf8f97914ea2e17dea07112.

Comment 5 John Mazzitelli 2011-11-30 17:00:52 UTC
verified this in master after jay's "revert the old commits and commit just the
changes we want to the drift metadata"

we need to cherry pick over to release branch

Comment 6 John Mazzitelli 2011-11-30 17:13:21 UTC
cherry pick from master (663c3c65527a5aacbcafead08614e4b416d52fa6) to release branch (b7e1b73df192f483f91dff5831b13d2741cdd165)

Comment 7 John Mazzitelli 2011-11-30 18:14:31 UTC
just to be clear how to test this:

Import a JBossAS 4 and 5 app server (I used the RHQ Server as the JbossAS 4 instance, I then started a stock EAP app server for the 5, I made sure I deployed a test .ear inside the 5 instance - for the 4 instance, just use the rhq.ear).

Make sure you can create drift templates for 4 and 5's:

1) EAR resource
2) standalone WAR resource (the stock EAP 5 instance has WAR apps in it)

So you should be able to create 4 drift templates all total.

Note that embedded WARs do not support drift now. We'll add that back in after release since its too late to add that functionality without causing paranoia.

Comment 8 Mike Foley 2012-02-07 19:22:24 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.