Bug 1000637 - Tomcat discovery fails to find version
Summary: Tomcat discovery fails to find version
Keywords:
Status: NEW
Alias: None
Product: RHQ Project
Classification: Other
Component: Plugins
Version: 4.8
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Nobody
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-08-23 22:23 UTC by Elias Ross
Modified: 2022-03-31 04:28 UTC (History)
1 user (show)

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


Attachments (Terms of Use)

Description Elias Ross 2013-08-23 22:23:04 UTC
TomcatDiscoveryComponent class calls the version.sh script. In my case, we repackaged the server to not include version.sh so my server version is 'Unknown Version'.

The version can also be obtained through JMX and is more reliable this way.

The suggestion (request) is to use the JMX obtained version when possible.

Comment 1 Heiko W. Rupp 2013-08-28 19:56:39 UTC
We are facing here the challenge that discovery is one phase and in many cases, the credentials can only be provided when the server is already in inventory, which means, discovery had happened.
While it may be true that the version can change on subsequent discovery runs (I'd need to check that), at least for the start we can only return "unknown" here.

We are thinking for the future of introducing a 2-phase discovery, where phase 1 only does the discovery and reports to the discovery Q, where the user can then give credentials if needed. Then 2nd phase kicks in and does the real discovery with name finding etc.

Comment 2 Elias Ross 2013-08-29 00:54:44 UTC
In some cases you want to be able to access the database/JMX/whatever connection to find the name, version, etc., so having a facet that's part of the resource itself, not part of the discovery class, would be ideal. I suppose it could be called after a start(), or be added as a method part of the resource's context.


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