[JBoss JIRA] Created: (JOPR-92) TC5: failure on shutdown operation (NPE)
by Heiko W. Rupp (JIRA)
TC5: failure on shutdown operation (NPE)
----------------------------------------
Key: JOPR-92
URL: https://jira.jboss.org/jira/browse/JOPR-92
Project: Jopr
Issue Type: Bug
Components: Plugin - Tomcat
Affects Versions: 2.2
Reporter: Heiko W. Rupp
Fix For: 2.2
Issued a shutdown operation
TC Server is shutting down, but the operation returns a failure
I get a failure to shut down:
ava.lang.NullPointerException
at org.jboss.on.plugins.tomcat.TomcatServerOperationsDelegate.shutdownViaScript(TomcatServerOperationsDelegate.java:276)
at org.jboss.on.plugins.tomcat.TomcatServerOperationsDelegate.shutdown(TomcatServerOperationsDelegate.java:247)
at org.jboss.on.plugins.tomcat.TomcatServerOperationsDelegate.invoke(TomcatServerOperationsDelegate.java:117)
at org.jboss.on.plugins.tomcat.TomcatServerComponent.invokeOperation(TomcatServerComponent.java:366)
Reason is that results.exitCode is null and
if (results.getExitCode() != 0) {
throw new RuntimeException("Error executing shutdown script while stopping Tomcat instance. Exit code [" + results.getExitCode() + "]");
}
the comparision in getExitCode != 0 tries to do an implicit intValue() on it which results in a NPE -- classical boxing issue
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years
[JBoss JIRA] Created: (JOPR-84) Make JBAS availability check take account of which actual instance is responding on jnp url
by Charles Crouch (JIRA)
Make JBAS availability check take account of which actual instance is responding on jnp url
-------------------------------------------------------------------------------------------
Key: JOPR-84
URL: https://jira.jboss.org/jira/browse/JOPR-84
Project: Jopr
Issue Type: Feature Request
Components: Plugin - JBoss AS 4
Affects Versions: 2.1
Reporter: Charles Crouch
Fix For: 2.2
Use case:
I have 2 JBAS instances on a box. Sometimes i run one instance, sometimes I run another, based on what application version I have deployed. Both instances have different install paths but share ip and port settings (which is fine because they dont both run at the same time)
Over time a JON agent running on this box will detect both instances so they can be added to the inventory. The issue is that in JON both resources will show as available because they both have the same jnp url.
The suggestion would be to make the getAvailabilityCheck be smarter so that the component recognizes when its querying an instance that its not associated with, e.g. on JBossASServerComponent
public AvailabilityType getAvailability() {
try {
EmsConnection connection = loadConnection();
EmsBean bean = connection.getBean("jboss.system:type=ServerConfig");
File serverHomeViaJNP = (File) bean.getAttribute("ServerHomeDir").refresh();
if (this.configPath.equals(serverHomeViaJNP))
return AvailabilityType.UP;
else
// a different server must have been started on our jnp url
return AvailabilityType.DOWN;
} catch (Exception e) {
return AvailabilityType.DOWN;
}
}
This is going to break existing resources (they will show red availability) where the configPath no longer matches where the instance is actually installed, though script/filesystem based operations (e.g. start, deploy apps) would already be broken for these resources. Re-inventorying the resources should fix this.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 1 month