|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.jonas.lib.management.extensions.base.JonasManagementRepr
public class JonasManagementRepr
Wrapper class allowing to apply a management operations (getAttribute, setAttribute, invoke, etc.) on the corresponding to managed server's connection. The managed server is identified by a name (serverName parameter). The corresponding connection is kept in the serverConnections table.
| Field Summary | |
|---|---|
protected static org.ow2.util.log.Log |
logger
Logger for traces. |
| Method Summary | |
|---|---|
static Object |
getAttribute(ObjectName on,
String attribute,
String serverName)
Gets the value of a specific attribute of a named MBean. |
static Object |
getAttribute(ObjectName on,
String attribute,
String jmxUrl,
String username,
String password)
Gets the value of a specific attribute of a named MBean. |
static AttributeList |
getAttributes(ObjectName on,
String[] attributes,
String serverName)
Gets the values of several attributes of a named MBean. |
static Object |
getAttributes(ObjectName on,
String[] attributes,
String jmxUrl,
String username,
String password)
Gets the values of several attributes of a named MBean. |
static MBeanInfo |
getMBeanInfo(ObjectName on,
String serverName)
|
static MBeanServerConnection |
getServerConnection(String serverName)
Return the MBeanServer connection corresponding to a given server in the current domain. |
static MBeanServerConnection |
getServerConnection(String jmxUrl,
String username,
String password)
Return the MBeanServer connection corresponding to a given server in the current domain. |
static Object |
invoke(ObjectName on,
String operation,
Object[] param,
String[] signature,
String serverName)
Implementation of the invoke method to be applied to a
server in the domain. |
static Object |
invoke(ObjectName on,
String operation,
Object[] param,
String[] signature,
String jmxUrl,
String username,
String password)
Implementation of the invoke method to be applied to a
server in the domain. |
static boolean |
isRegistered(ObjectName on,
String serverName)
Implementation of the isRegistered method to be applied to a
server in the domain. |
static boolean |
isRegistered(ObjectName on,
String jmxUrl,
String username,
String password)
Implementation of the isRegistered method to be applied to a
server identified by a JMX Url. |
static Set |
queryNames(ObjectName on,
String serverName)
|
static void |
setAttribute(ObjectName on,
String attribute,
Object value,
String serverName)
Sets the value of a specific attribute of a named MBean. |
static void |
setAttribute(ObjectName on,
String attribute,
Object value,
String jmxUrl,
String username,
String password)
Sets the value of a specific attribute of a named MBean. |
static void |
setAttributes(ObjectName on,
AttributeList attributes,
String serverName)
|
static void |
setAttributes(ObjectName on,
AttributeList attributes,
String jmxUrl,
String username,
String password)
|
static void |
unregisterMBean(ObjectName on,
String serverName)
Unregisters an MBean from the managed server's MBean server. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static org.ow2.util.log.Log logger
| Method Detail |
|---|
public static MBeanServerConnection getServerConnection(String serverName)
throws ManagementException
serverName - The managed server name
ManagementException - Couldn't get the connection
public static MBeanServerConnection getServerConnection(String jmxUrl,
String username,
String password)
throws ManagementException
jmxUrl - a server's jmx url.username - the user name in case the jmx server is protected by
user/password.password - the password in case the jmx server is protected by
user/password.
ManagementException - Couldn't get the connection
public static boolean isRegistered(ObjectName on,
String jmxUrl,
String username,
String password)
throws ManagementException
isRegistered method to be applied to a
server identified by a JMX Url.
on - ObjectName of the MBean we are looking forjmxUrl - a server's jmx url.username - the user name in case the jmx server is protected by
user/password.password - the password in case the jmx server is protected by
user/password.
ManagementException - management operation failed
public static boolean isRegistered(ObjectName on,
String serverName)
throws ManagementException
isRegistered method to be applied to a
server in the domain.
on - ObjectName of the MBean we are looking forserverName - The server name
ManagementException - management operation failed
public static Object getAttribute(ObjectName on,
String attribute,
String serverName)
throws ManagementException
on - The ObjectName of the MBean.attribute - A String specifying the name of the attribute to be
retrieved.serverName - The server name
ManagementException - management operation failed
public static Object getAttribute(ObjectName on,
String attribute,
String jmxUrl,
String username,
String password)
throws ManagementException
on - The ObjectName of the MBean.attribute - A String specifying the name of the attribute to be
retrieved.jmxUrl - a server's jmx url.username - the user name in case the jmx server is protected by
user/password.password - the password in case the jmx server is protected by
user/password.
ManagementException - management operation failed
public static AttributeList getAttributes(ObjectName on,
String[] attributes,
String serverName)
throws ManagementException
on - The ObjectName of the MBean.attributes - Array of attribute names to be retrieved.serverName - The server name
ManagementException - management operation failed
public static Object getAttributes(ObjectName on,
String[] attributes,
String jmxUrl,
String username,
String password)
throws ManagementException
on - The ObjectName of the MBean.attributes - Array of attribute names to be retrieved.jmxUrl - a server's jmx url.username - the user name in case the jmx server is protected by
user/password.password - the password in case the jmx server is protected by
user/password.
ManagementException - management operation failed
public static void setAttribute(ObjectName on,
String attribute,
Object value,
String serverName)
throws ManagementException
on - The ObjectName of the MBean.serverName - The server nameattribute - A String specifying the name of the attribute to be set.value - The value to set to the attribute.
ManagementException - management operation failed
public static void setAttribute(ObjectName on,
String attribute,
Object value,
String jmxUrl,
String username,
String password)
throws ManagementException
on - The ObjectName of the MBean.attribute - A String specifying the name of the attribute to be set.value - The value to set to the attribute.jmxUrl - a server's jmx url.username - the user name in case the jmx server is protected by
user/password.password - the password in case the jmx server is protected by
user/password.
ManagementException - management operation failed
public static void setAttributes(ObjectName on,
AttributeList attributes,
String serverName)
throws ManagementException
on - The ObjectName of the MBean within which the attribute is to be
set.serverName - The server nameattributes - A list of attributes: The identification of the
attribute to be set and the value it is to be set to
ManagementException - management operation failed
public static void setAttributes(ObjectName on,
AttributeList attributes,
String jmxUrl,
String username,
String password)
throws ManagementException
on - The ObjectName of the MBean within which the attribute is to be
set.attributes - A list of attributes: The identification of the
attribute to be set and the value it is to be set tojmxUrl - a server's jmx url.username - the user name in case the jmx server is protected by
user/password.password - the password in case the jmx server is protected by
user/password.
ManagementException - management operation failed
public static Object invoke(ObjectName on,
String operation,
Object[] param,
String[] signature,
String serverName)
throws ManagementException
invoke method to be applied to a
server in the domain.
on - the ObjectName of the MBean that is the target of the invoke.operation - operation to invokeparam - invoke parameterssignature - invoke parameters signatureserverName - The server's name
ManagementException - management operation failed
public static Object invoke(ObjectName on,
String operation,
Object[] param,
String[] signature,
String jmxUrl,
String username,
String password)
throws ManagementException
invoke method to be applied to a
server in the domain.
on - the ObjectName of the MBean that is the target of the invoke.operation - operation to invokeparam - invoke parameterssignature - invoke parameters signaturejmxUrl - a server's jmx url.username - the user name in case the jmx server is protected by
user/password.password - the password in case the jmx server is protected by
user/password.
ManagementException - management operation failed
public static Set queryNames(ObjectName on,
String serverName)
throws ManagementException
on - MBean nameserverName - The server name
ManagementException - management operation failed
public static MBeanInfo getMBeanInfo(ObjectName on,
String serverName)
throws ManagementException
name - MBean's ObjectNameserverName - The server name
ManagementException - management operation failed
public static void unregisterMBean(ObjectName on,
String serverName)
throws ManagementException
on - The object name of the MBean.serverName - The server name
ManagementException - wraps exception thrown by the called
management operation
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||