Bug 1123834

Summary: [AS7] app is not available after plugin update
Product: [JBoss] JBoss Operations Network Reporter: Armine Hovsepyan <ahovsepy>
Component: Plugin -- JBoss EAP 6, UpgradeAssignee: RHQ Project Maintainer <rhq-maint>
Status: CLOSED NOTABUG QA Contact: Mike Foley <mfoley>
Severity: urgent Docs Contact:
Priority: unspecified    
Version: JON 3.3.0CC: ahovsepy, jshaughn, mfoley
Target Milestone: ---Keywords: Regression
Target Release: JON 3.3.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-07-29 09:59:01 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:
Bug Depends On:    
Bug Blocks: 1070326    
Attachments:
Description Flags
update_plugin none

Description Armine Hovsepyan 2014-07-28 11:45:05 UTC
Created attachment 921756 [details]
update_plugin

Description of problem:
AS7 app is not available after plugin update

Version-Release number of selected component (if applicable):
RHQ 4.13 latest master

How reproducible:
always

Steps to Reproduce:
1. Install and start  rhq 4.11 using 'rhqctl install --start' command
2. install and start jboss eap 6 on the same env as rhq from step1
3. inventory eap6 to server gui
4. deploy helloworld-1.2.2.war to eap6
5. deploy helloworld-2.1.0.war to eap6
6. stop and remove helloworld-1.2.2.war 
7. update rhq 4.11 to latest 4.13 following steps below:
 1. stop eap server 
 2. stop rhq using 'rhqctl stop' command
 3. run 'rhqctl upgrade --from-server-dir=PathToRHQ411'
 4. stat rhq 4.13 with 'rhqctl start' command
 5. start jboss eap6 

Actual results:
both helloworld wars are inventoried and are not available with the following message:
Upgrading the resource [Resource[id=10876, uuid=7bd3bbee-11c4-48bf-8f77-35900adcb706, type={JBossAS7}Deployment, key=deployment=helloworld-2.1.0.war, name=helloworld-2.1.0.war, parent=EAP (0.0.0.0:9990), version=2.1.0]] using these updates [ResourceUpgradeRequest [resourceId=10876, upgradeErrorMessage=null, upgradeErrorStackTrace=null, timestamp=1406543939500, toString()=ResourceUpgradeReport [newResourceKey=deployment=helloworld.war, newName=helloworld.war, newVersion=2.1.0, newDescription=null, newPluginConfiguration=null, forceGenericPropertyUpgrade=true]]] would render the inventory invalid because of the following reasons: After the upgrade, the following resources would have the same resource key which is illegal. This is an issue of either the old or the new version of the plugin 'JBossAS7'. Please consult the documentation of the plugin to see what are the recommended steps to resolve this situation:
Resource[id=10966, uuid=9dee62ea-30f4-442e-829a-50ceee18dc95, type={JBossAS...


Expected results:
apps installed before the plugin updated should be visible with the same availability as before the upgrade


Additional info:
screen-shot attached

Comment 1 Armine Hovsepyan 2014-07-28 14:20:06 UTC
removing undeployed war does not fix the issue

Comment 2 Jay Shaughnessy 2014-07-28 18:10:29 UTC
Your expected results aren't really possible given versioned deployments. This is working as expected.  If you want the desired behavior you need to disable versioned deployments by setting:

  -Drhq.as7.VersionedSubsystemDiscovery.pattern=disable

for the agent.

Comment 3 Armine Hovsepyan 2014-07-29 09:59:01 UTC
Test case tuned. Closing as not a bug.

Thank you!