Bug 791340 - Exploded WAR deployed through JON never added to inventory
Summary: Exploded WAR deployed through JON never added to inventory
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Operations Network
Classification: JBoss
Component: Plugin -- JBoss EAP 5
Version: JON 3.0.0
Hardware: i686
OS: Linux
medium
medium
Target Milestone: DR01
: JON 3.2.0
Assignee: Thomas Segismont
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-02-16 19:39 UTC by David van Balen
Modified: 2014-01-02 20:43 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-01-02 20:43:11 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
agent's inventory scan (28.95 KB, text/plain)
2012-02-16 19:39 UTC, David van Balen
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 669542 0 high CLOSED Deploying exploded WAR to JBoss EAP 5 throws NPE operation fails 2021-02-22 00:41:40 UTC

Description David van Balen 2012-02-16 19:39:57 UTC
Created attachment 562576 [details]
agent's inventory scan

Description of problem:

I deployed a WAR archive to a JBoss EAP 5.1.2 server through the "Create Child" menu. The artifact was deployed successfully, and the JON server reports that the deployment was successful. However, the artifact never showed up in the inventory for the server in question. When an inventory scan is run on the agent, the artifact is recognized, but always shows up as "sync=NEW" and "avail=UNKNOWN"

See attachments.


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

JON Server 3.0.0, EAP plugin pack 3.0.0, JON Agent 4.2.0.JON300.GA, Fedora Linux 14, JBoss EAP 5.1.2


How reproducible:

Has only happened once.


Steps to Reproduce:
1. Create a war file containing a simple hello world servlet
2. Navigate to Inventory tab of imported EAP 5.1.2 server
3. Choose Create Child -> Web Application (WAR)
4. Input a version (I used 1.0), upload the war, select option for deploying exploded.
  
Actual results:

JON reports successful deployment, but does not display newly deployed exploded war under the server's inventory. Searching under "All Resources" does not produce any results, and, although Agent seems to see the deployed resource, it can't seem to see it's availability and always thinks it's a new resource.

Expected results:

Once exploded war is successfully deployed, it should show up under the EAP server's inventory list.


Additional info:

Comment 1 David van Balen 2012-02-16 20:11:40 UTC
I tried this with a different server and couldn't reproduce, so it might be related to an earlier problem I had with deleting a different war from the command line that had been deployed through JON. I'll see if I can reproduce that.

Comment 2 Mike Foley 2012-03-05 16:58:11 UTC
asynchronous systems, will not see artifacts instantly.  need to wait up to 24 hours (default discovery scan for servers). 

possible enhancement here can mitigate.

Comment 3 Larry O'Leary 2012-03-05 17:16:45 UTC
This issue seems to describe something that we see quite frequently in JON. It deals with timing in regards to the deployment of a resource and the discovery of the newly deployed resource.

Normally, JON performs a service level discovery scan once every 24 hours. This would include EARs and WARs and their enclosed/embedded resources. However, when a resource is deployed using the Create New function an attempt to discover the newly added resource is triggered immediately. However, if for some reason the newly created resource does not get fully deployed by the time the discovery attempt is performed or not all its enclosed/embedded resources have been fully deployed by the time the parent WAR/EAR has been successfully deployed, the services will be missing from inventory until the next scheduled service discovery is performed.

Comment 4 Heiko W. Rupp 2013-08-13 08:12:42 UTC
Thomas, could you investigate this? 
Perhaps doing something along the lines of 

if (1st discovery != success } {
  wait_a_minute;
  retry_discovery;
}

I would not post those re-tries forever though, as it may be that the uploaded resource is just broken and will never successfully be up at all.

Comment 5 Thomas Segismont 2013-08-22 15:06:03 UTC
Fixed in master

commit 75845aad84cc337b76e568b3afa1b989bc15ecce
Author: Thomas Segismont <tsegismo>
Date:   Thu Aug 22 17:04:12 2013 +0200

When a new resource deployment takes some time, the CreateResourceRunner won't be able to discover the new resource. Eventually, the user will have to wait for next automatic service scan to see the resource in the inventory, or will have to trigger a service scan manually.
 
Now CreateResourceRunner will try up to five times to detect the new resource, with a 30 seconds pause between tries. That gives the managed server up to 5 minutes to deploy it.

Comment 6 Simeon Pinder 2013-12-13 15:43:20 UTC
Moving this to ON_QA, as discussed in triage triage call (myarboro,loleary,spinder). This is already in the GA tag but somehow we didn't set this to ON_QA.


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