public void getOptimizerTables(Context ctx) {
    String optimizerGroup = ctx.pathParam("optimizerGroup");
    String dbFilterStr = ctx.queryParam("dbSearchInput");
    String tableFilterStr = ctx.queryParam("tableSearchInput");
    Integer page = ctx.queryParamAsClass("page", Integer.class).getOrDefault(1);
    Integer pageSize = ctx.queryParamAsClass("pageSize", Integer.class).getOrDefault(20);
    Set<String> actionFilter = new HashSet<>(ctx.queryParams("actions[]"));
    int offset = (page - 1) * pageSize;

    String optimizerGroupUsedInDbFilter = ALL_GROUP.equals(optimizerGroup) ? null : optimizerGroup;
    // get all info from underlying table table_runtime
    List<Integer> statusCodes = new ArrayList<>(actionFilter.size());
    for (String action : actionFilter) {
      OptimizingStatus status = OptimizingStatus.ofDisplayValue(action);
      if (status == null) {
        LOG.warn("Can't find optimizer status for action:{}, skip it.", action);
      } else {
        statusCodes.add(status.getCode());
      }
    }

    // use null to mark the filter as null filter
    if (statusCodes.isEmpty()) {
      statusCodes = null;
    }
    Pair<List<TableOptimizingInfo>, Integer> tableRuntimeBeans =
        tableManager.queryTableOptimizingInfo(
            optimizerGroupUsedInDbFilter,
            dbFilterStr,
            tableFilterStr,
            statusCodes,
            pageSize,
            offset);
    PageResult<TableOptimizingInfo> amsPageResult =
        PageResult.of(tableRuntimeBeans.getLeft(), tableRuntimeBeans.getRight());
    ctx.json(OkResponse.of(amsPageResult));
  }
Get optimize tables. * @return List of {@link TableOptimizingInfo}
amoro-ams/src/main/java/org/apache/amoro/server/dashboard/controller/OptimizerGroupController.java