]
Brian Stansberry updated JBAS-7785:
-----------------------------------
JBoss Forum Reference:
JBossManager cannot register mbean for root context
---------------------------------------------------
Key: JBAS-7785
URL:
https://jira.jboss.org/jira/browse/JBAS-7785
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Clustering
Affects Versions: JBossAS-5.1.0.GA, JBossAS-6.0.0.M1, JBossAS-6.0.0.M2
Reporter: Brian Stansberry
Assignee: Brian Stansberry
Fix For: JBossAS-6.0.0.M3
When JBossManager attempts to register an mbean for itself when it's the manager for
a root context (i.e. one who's path is "") it fails with
javax.management.MalformedObjectNameException: Unterminated key property part.
Problem is the ObjectName construction logic is failing to deal with the empty path:
ObjectName clusterName = new ObjectName(domain
+ ":type=Manager,host=" + hostName + ",path="
+ ((Context) container_).getPath());
Fix is:
String path = ((Context) container_).getPath();
path = "".equals(path) ? "/" : path;
ObjectName clusterName = new ObjectName(domain
+ ":type=Manager,host=" + hostName + ",path="
+ path);
Using / as the path is consistent with how StandardContext creates an ObjectName for
itself.
This bug ObjectName results in an ERROR in the server log and the mbean for the session
manager not being registered, but it doesn't prevent normal operation of the session
manager.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: