int start = Integer.parseInt(commandLine.getOptionValue("start"));
int end = Integer.parseInt(commandLine.getOptionValue("end"));
JMXClient jmxClient = JMXClient.getJMXClient(host, port);
this.println("connected to " + jmxClient.getAddressAsString());
ObjectInstance metaConfigInstance = jmxClient.queryMBeanForOne(METACONFIG_NAME);
if (metaConfigInstance != null) {
jmxClient.invoke(metaConfigInstance.getObjectName(), "closePartitions", new Object[] { topic, start, end },
new String[] { "java.lang.String", "int", "int" });
jmxClient.close();