public static String getCommmand() throws MalformedObjectNameException, IOException {
    RuntimeMXBean runtimeBean = ManagementFactory.getRuntimeMXBean();
    return runtimeBean.getSystemProperties().get("sun.java.command");
  }
Method for building map used for constructing ObjectName. Mapping is done with arrays indices
@param keys   Map keys
@param values Map values
@return Map or null if arrays are empty or have different number of elements
hbase-http/src/main/java/org/apache/hadoop/hbase/util/JSONMetricUtil.java