public InformationSchemaQueryIterable()

in bigquery-antipattern-recognition/src/main/java/com/google/zetasql/toolkit/antipattern/cmd/InformationSchemaQueryIterable.java [38:67]


  public InformationSchemaQueryIterable(String processingProjectId, String customDaysBack,
      String startTime,
      String endTime, String customISTable, String infoSchemaSlotmsMin, String customTimeoutInSecs,
      String customTopNPercent, String customRegion, String customInfoSchemaProject,
      String serviceAccountKeyfilePath)
      throws InterruptedException, IOException {

    String daysBack = customDaysBack == null ? DAYS_BACK_DEFAULT : customDaysBack;
    String region = customRegion == null ? DEFAULT_REGION : customRegion;
    String infoSchemaProject =
        customInfoSchemaProject == null ? processingProjectId : customInfoSchemaProject;
    String ISTable =
        customISTable == null ? String.format(IS_TABLE_DEFAULT, infoSchemaProject, region)
            : customISTable;
    Integer slotsMsMin =
        infoSchemaSlotmsMin == null ? SLOTMS_MIN_DEFAULT : Integer.parseInt(infoSchemaSlotmsMin);
    Long timeoutInSecs = !NumberUtils.isParsable(customTimeoutInSecs) ? TIMEOUT_SECS_DEFAULT
        : Long.parseLong(customTimeoutInSecs);
    float topNPercent =
        customTopNPercent == null ? TOP_N_PERC_DEFAULT : Float.parseFloat(customTopNPercent);

    BigQueryHelper bigQueryHelper = new BigQueryHelper(processingProjectId,
        serviceAccountKeyfilePath);

    TableResult tableResult =
        bigQueryHelper.getQueriesFromIS(daysBack, startTime, endTime, ISTable, slotsMsMin,
            timeoutInSecs, topNPercent, region);

    fieldValueListIterator = tableResult.iterateAll().iterator();
  }