private static Set<String> getMonitorNames(Config config) {
    Set<String> monitorNames = new HashSet<>();
    for (String configKey : config.keySet()) {
      String[] configKeyComponents = StringUtils.split(configKey, MONITOR_CONFIG_KEY_SEPARATOR);
      Preconditions.checkState(configKeyComponents.length != 0);
      String monitorName = configKeyComponents[0];
      monitorNames.add(monitorName);
    }
    return monitorNames;
  }
@param config contains all the configuration that are defined for the monitors.
@return a unique collection of monitor names for which configuration has been defined in the config object
samza-rest/src/main/java/org/apache/samza/monitor/MonitorConfig.java