apollo-portal/src/main/java/com/ctrip/framework/apollo/portal/controller/SystemInfoController.java/SystemInfoController/checkHealth
class SystemInfoController:  @PreAuthorize(value = "@permissionValidator.isSuperAdmin()")
  @GetMapping(value = "/health")
  public Health checkHealth(@RequestParam String instanceId) {
    List<Env> allEnvs = portalSettings.getAllEnvs();

    ServiceDTO service = null;
    for (final Env env : allEnvs) {
      EnvironmentInfo envInfo = adaptEnv2EnvironmentInfo(env);
      if (envInfo.getAdminServices() != null) {
        for (final ServiceDTO s : envInfo.getAdminServices()) {
          if (instanceId.equals(s.getInstanceId())) {
            service = s;
            break;
          }
        }
      }
      if (envInfo.getConfigServices() != null) {
        for (final ServiceDTO s : envInfo.getConfigServices()) {
          if (instanceId.equals(s.getInstanceId())) {
            service = s;
            break;
          }
        }
      }
    }

    if (service == null) {
      throw new IllegalArgumentException("No such instance of instanceId: " + instanceId);
    }

    return restTemplate.getForObject(service.getHomepageUrl() + "/health", Health.class);
  }