Bug 699870 - [JBoss AS] Discovery of AS instance fails if AS configDir is a URL
Summary: [JBoss AS] Discovery of AS instance fails if AS configDir is a URL
Keywords:
Status: NEW
Alias: None
Product: RHQ Project
Classification: Other
Component: Plugins
Version: 4.0.0
Hardware: All
OS: All
medium
medium
Target Milestone: ---
: ---
Assignee: Nobody
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-04-26 19:41 UTC by Larry O'Leary
Modified: 2022-03-31 04:28 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description Larry O'Leary 2011-04-26 19:41:15 UTC
Description of problem:
An AS instance which uses a URL for its system property jboss.server.home.dir can not be discovered because the plug-in claims the configuration directory does not exist or is not a directory:

Skipping discovery for JBoss AS process process: pid=[12255], name=[java], ppid=[12251], because configuration dir 'file:///opt/jboss/jboss-eap-5.1/jboss-as/server/default' does not exist or is not a directory.

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

How reproducible:
Always

Steps to Reproduce:
1. Start an EAP 5 instance using ./run.sh -c default -b 0.0.0.0 -Djboss.server.home.dir=file:///opt/jboss/eap/jboss-eap-5.1/jboss-as/server/default
2. Force a discovery scan for the agent running on the platform for this EAP server
  
Actual results:
EAP 5 instance is not discovered and agent logs the following warning:
WARN  [ResourceDiscoveryComponent.invoker.daemon-837] (org.rhq.plugins.jbossas5.ApplicationServerDiscoveryComponent)- Skipping discovery for JBoss AS process process: pid=[6314], name=[/usr/lib/jvm/java-1.6.0-sun-1.6.0.24/bin/java], ppid=[6267], because configuration dir 'file:/opt/jboss/eap/jboss-eap-5.1/jboss-as/server/default does not exist or is not a directory.


Expected results:
EAP 5 instance should be discovered and no warning is logged

Additional info:
This issue is caused by the assumption that the value for jboss.server.home.dir is a File. Instead, we should account for the possibility that a URL is provided instead of a file system path.


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