Description of problem: If the connection to the Tomcat server fails for any reason, we end up swallowing the entire exception and simply mark it as down. Availability check of TomcatServerComponent should not fail silently as it does at the moment. This is due to: org.jboss.on.plugins.tomcat.TomcatServerComponent.getAvailability() catching all exceptions and simply returning availability as DOWN: } catch (Exception e) { // If the connection is not servicing requests then close it. this seems necessary for the // Tomcat connection as when Tomcat does come up again it seems a new EMS connection is required, // otherwise we're not seeing EMS be able to pick up the new process. closeConnection(); }return AvailabilityType.DOWN; } Version-Release number of selected component (if applicable): JON 2.4.0 JON 2.4.1 How reproducible: Every time Steps to Reproduce: 1. I reproduced this with Tomcat 5.0.30 2. 3. Actual results: Tomcat is marked as DOWN but no exception is logged in the agent.log file Expected results: Tomcat is marked as DOWN and the agent.log file contains the appropriate exception. Additional info:
If an exception is thrown by the connection to the Tomcat instance, we should capture this when in debug mode.
Created attachment 522968 [details] Proposed patch against release-3.0.1 branch Proposed log change. Although minor, still needs a code review before it can be committed anywhere.
This is also done in master: http://git.fedorahosted.org/git/?p=rhq/rhq.git;a=commitdiff;h=1fcca6b
Moving to ON_QA for testing with JON 3.0.1.GA RC5 or better: https://brewweb.devel.redhat.com//buildinfo?buildID=199114