public class JMXClient extends Object
| Constructor and Description |
|---|
JMXClient()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
doSubCommand(MBeanServerConnection mbsc,
ObjectInstance instance,
String subCommand) |
Object[] |
execute(String hostport,
String login,
String password,
String beanname,
String[] command) |
Object[] |
execute(String hostport,
String login,
String password,
String beanname,
String[] command,
boolean oneBeanOnly)
Execute command against remote JMX agent.
|
Object[] |
executeOneCmd(String hostport,
String login,
String password,
String beanname,
String command) |
static void |
main(String[] args) |
public Object[] execute(String hostport, String login, String password, String beanname, String[] command) throws Exception
Exceptionpublic Object[] executeOneCmd(String hostport, String login, String password, String beanname, String command) throws Exception
Exceptionpublic Object[] execute(String hostport, String login, String password, String beanname, String[] command, boolean oneBeanOnly) throws Exception
hostport - 'host:port' combination.login - RMI login to use.password - RMI password to use.beanname - Name of remote bean to run command against.command - Array of commands to run.oneBeanOnly - Set true if passed beanname is
an exact name and the query for a bean is only
supposed to return one bean instance. If not, we raise
an exception (Otherwise, if false, then we deal with
possibility of multiple bean instances coming back
from query). Set to true when want to get an attribute
or run an operation.Exception - on errorpublic Object doSubCommand(MBeanServerConnection mbsc, ObjectInstance instance, String subCommand) throws Exception
ExceptionCopyright 2004-2019 Solace Corporation. All rights reserved.