def _parse_hosts_list(self, job_dict, job_name):
      self.hosts = {}
      self.hostnames = {}
      for name, value in job_dict.iteritems():
        reg_expr = HOST_RULE_REGEX.match(name)
        if not reg_expr:
          continue
        host_id = int(reg_expr.group("id"))
        self.hosts[host_id] = ServiceConfig.Jobs.Hosts(value)

        ip = self.hosts[host_id].ip
        try:
          self.hostnames[host_id] = socket.gethostbyaddr(ip)[0]
        except:
          self.hostnames[host_id] = ip

        instance_num = self.hosts[host_id].instance_num
        if instance_num > 1 and job_name not in MULTIPLE_INSTANCES_JOBS:
          Log.print_critical("The job %s doesn't support for multiple instances" \
            " on the same host. Please check your config." % job_name)
Parse the hosts list for job
dataset/ETHPy150Open XiaoMi/minos/client/service_config.py/ServiceConfig.Jobs._parse_hosts_list