Program: 114917
Project: 114917
Buggy source:
private void updateTiers() throws APIMigrationException {
  log.info("String_Node_Str");
  for (  Tenant tenant : getTenantsArray()) {
    log.debug("String_Node_Str" + tenant.getId() + '('+ tenant.getDomain()+ ')');
    try {
      registryService.startTenantFlow(tenant);
      if (!registryService.isGovernanceRegistryResourceExists(APIConstants.API_TIER_LOCATION)) {
        continue;
      }
 else {
        String apiTiers=ResourceUtil.getResourceContent(registryService.getGovernanceRegistryResource(APIConstants.API_TIER_LOCATION));
        String updatedApiTiers=ResourceModifier.modifyTiers(apiTiers,APIConstants.API_TIER_LOCATION);
        registryService.updateGovernanceRegistryResource(APIConstants.API_TIER_LOCATION,updatedApiTiers);
      }
      if (!registryService.isGovernanceRegistryResourceExists(APIConstants.APP_TIER_LOCATION)) {
        String apiTiers=ResourceUtil.getResourceContent(registryService.getGovernanceRegistryResource(APIConstants.API_TIER_LOCATION));
        registryService.addGovernanceRegistryResource(APIConstants.APP_TIER_LOCATION,apiTiers,"String_Node_Str");
      }
      if (!registryService.isGovernanceRegistryResourceExists(APIConstants.RES_TIER_LOCATION)) {
        String apiTiers=ResourceUtil.getResourceContent(registryService.getGovernanceRegistryResource(APIConstants.API_TIER_LOCATION));
        registryService.addGovernanceRegistryResource(APIConstants.RES_TIER_LOCATION,apiTiers,"String_Node_Str");
      }
    }
 catch (    UserStoreException e) {
      log.error("String_Node_Str" + +tenant.getId() + '('+ tenant.getDomain()+ ')',e);
    }
catch (    RegistryException e) {
      log.error("String_Node_Str" + +tenant.getId() + '('+ tenant.getDomain()+ ')',e);
    }
 finally {
      registryService.endTenantFlow();
    }
    log.debug("String_Node_Str" + tenant.getId() + '('+ tenant.getDomain()+ ')');
  }
  log.info("String_Node_Str");
}

Fixed version (ground truth):
private void updateTiers() throws APIMigrationException {
  log.info("String_Node_Str");
  for (  Tenant tenant : getTenantsArray()) {
    log.info("String_Node_Str" + tenant.getId() + '('+ tenant.getDomain()+ ')');
    try {
      registryService.startTenantFlow(tenant);
      if (!registryService.isGovernanceRegistryResourceExists(APIConstants.API_TIER_LOCATION)) {
        continue;
      }
 else {
        String apiTiers=ResourceUtil.getResourceContent(registryService.getGovernanceRegistryResource(APIConstants.API_TIER_LOCATION));
        String updatedApiTiers=ResourceModifier.modifyTiers(apiTiers,APIConstants.API_TIER_LOCATION);
        registryService.updateGovernanceRegistryResource(APIConstants.API_TIER_LOCATION,updatedApiTiers);
      }
      if (!registryService.isGovernanceRegistryResourceExists(APIConstants.APP_TIER_LOCATION)) {
        String apiTiers=ResourceUtil.getResourceContent(registryService.getGovernanceRegistryResource(APIConstants.API_TIER_LOCATION));
        registryService.addGovernanceRegistryResource(APIConstants.APP_TIER_LOCATION,apiTiers,"String_Node_Str");
      }
      if (!registryService.isGovernanceRegistryResourceExists(APIConstants.RES_TIER_LOCATION)) {
        String apiTiers=ResourceUtil.getResourceContent(registryService.getGovernanceRegistryResource(APIConstants.API_TIER_LOCATION));
        registryService.addGovernanceRegistryResource(APIConstants.RES_TIER_LOCATION,apiTiers,"String_Node_Str");
      }
    }
 catch (    UserStoreException e) {
      log.error("String_Node_Str" + +tenant.getId() + '('+ tenant.getDomain()+ ')',e);
    }
catch (    RegistryException e) {
      log.error("String_Node_Str" + +tenant.getId() + '('+ tenant.getDomain()+ ')',e);
    }
 finally {
      registryService.endTenantFlow();
    }
    log.info("String_Node_Str" + tenant.getId() + '('+ tenant.getDomain()+ ')');
  }
  log.info("String_Node_Str");
}