reworked JMX for new layout
git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@175 7e9141cc-0065-0410-87d8-b60c137991c4
This commit is contained in:
parent
ee0b036e26
commit
39146e96a2
|
@ -11,7 +11,7 @@
|
|||
// You may elect to redistribute this code under either of these licenses.
|
||||
// ========================================================================
|
||||
|
||||
package org.eclipse.jetty.jmx.handler;
|
||||
package org.eclipse.jetty.handler.jmx;
|
||||
|
||||
import java.util.Enumeration;
|
||||
import java.util.HashMap;
|
|
@ -89,8 +89,8 @@ public class ObjectMBean implements DynamicMBean
|
|||
*
|
||||
* Then this method would look for the following classes:
|
||||
* <UL>
|
||||
* <LI>com.acme.management.MyClassMBean
|
||||
* <LI>com.acme.util.management.BaseClassMBean
|
||||
* <LI>com.acme.jmx.MyClassMBean
|
||||
* <LI>com.acme.util.jmx.BaseClassMBean
|
||||
* <LI>org.eclipse.jetty.jmx.ObjectMBean
|
||||
* </UL>
|
||||
*
|
||||
|
@ -108,7 +108,7 @@ public class ObjectMBean implements DynamicMBean
|
|||
{
|
||||
String pName = oClass.getPackage().getName();
|
||||
String cName = oClass.getName().substring(pName.length() + 1);
|
||||
String mName = pName + ".management." + cName + "MBean";
|
||||
String mName = pName + ".jmx." + cName + "MBean";
|
||||
|
||||
|
||||
try
|
||||
|
@ -227,7 +227,7 @@ public class ObjectMBean implements DynamicMBean
|
|||
oClass=ObjectMBean.class;
|
||||
String pName = oClass.getPackage().getName();
|
||||
String cName = oClass.getName().substring(pName.length() + 1);
|
||||
String rName = pName.replace('.', '/') + "/management/" + cName+"-mbean";
|
||||
String rName = pName.replace('.', '/') + "/jmx/" + cName+"-mbean";
|
||||
|
||||
try
|
||||
{
|
||||
|
@ -585,9 +585,14 @@ public class ObjectMBean implements DynamicMBean
|
|||
}
|
||||
}
|
||||
|
||||
if (convert && type.isPrimitive() && !type.isArray())
|
||||
throw new IllegalArgumentException("Cannot convert primative " + name);
|
||||
|
||||
if (convert)
|
||||
{
|
||||
if (type==null)
|
||||
throw new IllegalArgumentException("No type for " + name+" on "+_managed.getClass());
|
||||
|
||||
if (type.isPrimitive() && !type.isArray())
|
||||
throw new IllegalArgumentException("Cannot convert primative " + name);
|
||||
}
|
||||
|
||||
if (getter == null && setter == null)
|
||||
throw new IllegalArgumentException("No getter or setters found for " + name+ " in "+oClass);
|
||||
|
|
|
@ -11,8 +11,9 @@
|
|||
// You may elect to redistribute this code under either of these licenses.
|
||||
// ========================================================================
|
||||
|
||||
package org.eclipse.jetty.jmx;
|
||||
package org.eclipse.jetty.server.jmx;
|
||||
|
||||
import org.eclipse.jetty.jmx.ObjectMBean;
|
||||
import org.eclipse.jetty.server.Handler;
|
||||
import org.eclipse.jetty.server.Server;
|
||||
import org.eclipse.jetty.server.handler.ContextHandler;
|
|
@ -11,7 +11,7 @@
|
|||
// You may elect to redistribute this code under either of these licenses.
|
||||
// ========================================================================
|
||||
|
||||
package org.eclipse.jetty.jmx.servlet;
|
||||
package org.eclipse.jetty.servlet.jmx;
|
||||
|
||||
import org.eclipse.jetty.jmx.ObjectMBean;
|
||||
import org.eclipse.jetty.servlet.Holder;
|
|
@ -11,9 +11,9 @@
|
|||
// You may elect to redistribute this code under either of these licenses.
|
||||
// ========================================================================
|
||||
|
||||
package org.eclipse.jetty.jmx.webapp;
|
||||
package org.eclipse.jetty.webapp.jmx;
|
||||
|
||||
import org.eclipse.jetty.jmx.handler.ContextHandlerMBean;
|
||||
import org.eclipse.jetty.handler.jmx.ContextHandlerMBean;
|
||||
import org.eclipse.jetty.webapp.WebAppContext;
|
||||
|
||||
public class WebAppContextMBean extends ContextHandlerMBean
|
|
@ -1,4 +1,4 @@
|
|||
Context: Servlet Context Handler
|
||||
ServletContextHandler: Servlet Context Handler
|
||||
securityHandler: MObject: The context's security handler
|
||||
servletHandler: MObject: The context's servlet handler
|
||||
sessionHandler: MObject: The context's session handler
|
Loading…
Reference in New Issue