com.netflix.adminresources.resources.jmx
Class JMXResource

java.lang.Object
  extended by com.netflix.adminresources.resources.jmx.JMXResource

public class JMXResource
extends java.lang.Object

Resource to expose JMX via JSON


Constructor Summary
JMXResource()
           
 
Method Summary
 javax.ws.rs.core.Response getMBean(java.lang.String key, java.lang.String jsonp)
          Return all the attributes and operations for a single mbean
 javax.ws.rs.core.Response getMBeans(java.lang.String key, java.lang.String mode, java.lang.String jsonp)
          Return JSON representing the entire tree of MBeans in DynaTree format.
 javax.ws.rs.core.Response getMBeansByRegex(java.lang.String objNameRegex, java.lang.String jsonp)
          Return all the attributes and operations for a MBeans whose ObjectNames match the passed in regex.
 javax.ws.rs.core.Response invokeMbeanOperation(javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> formParams, java.lang.String key, java.lang.String jsonp, java.lang.String name)
          Execute an operation on an mbean.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JMXResource

public JMXResource()
Method Detail

getMBeans

public javax.ws.rs.core.Response getMBeans(java.lang.String key,
                                           java.lang.String mode,
                                           java.lang.String jsonp)
                                    throws java.lang.Exception
Return JSON representing the entire tree of MBeans in DynaTree format.

Parameters:
key -
mode -
Throws:
java.lang.Exception

getMBean

public javax.ws.rs.core.Response getMBean(java.lang.String key,
                                          java.lang.String jsonp)
                                   throws java.lang.Exception
Return all the attributes and operations for a single mbean

Parameters:
key - Exact object name of MBean in String form
jsonp -
Throws:
java.lang.Exception

invokeMbeanOperation

public javax.ws.rs.core.Response invokeMbeanOperation(javax.ws.rs.core.MultivaluedMap<java.lang.String,java.lang.String> formParams,
                                                      java.lang.String key,
                                                      java.lang.String jsonp,
                                                      java.lang.String name)
                                               throws java.lang.Exception
Execute an operation on an mbean.

Parameters:
formParams -
key -
jsonp -
name -
Throws:
java.lang.Exception

getMBeansByRegex

public javax.ws.rs.core.Response getMBeansByRegex(java.lang.String objNameRegex,
                                                  java.lang.String jsonp)
Return all the attributes and operations for a MBeans whose ObjectNames match the passed in regex.

Parameters:
objNameRegex - regex for ObjectName of MBean(s). The ObjectName documentation explains what kinds of regex expressions are valid
jsonp - if non-empty, Jsonp output is returned instead of Json