public static Options getUpsertOptions()

in odps-console-dship/src/main/java/com/aliyun/odps/ship/common/OptionsBuilder.java [837:886]


  public static Options getUpsertOptions() {
    Options opts = getGlobalOptions();
    opts.addOption(
        Option.builder("dbr")
            .longOpt(Constants.DISCARD_BAD_RECORDS)
            .hasArg()
            .argName("ARG")
            .desc("specify discard bad records action(true|false), default " +
                  Constants.DEFAULT_DISCARD_BAD_RECORDS)
            .build());
    opts.addOption(
        Option.builder("bs")
            .longOpt(Constants.BLOCK_SIZE)
            .hasArg()
            .argName("ARG")
            .desc("block size in MiB, default " + Constants.DEFAULT_BLOCK_SIZE)
            .build());
    opts.addOption(
        Option.builder("mbr")
            .longOpt(Constants.MAX_BAD_RECORDS)
            .hasArg()
            .argName("ARG")
            .desc("max bad records, default " + Constants.DEFAULT_BAD_RECORDS)
            .build());
    opts.addOption(
        Option.builder("acp")
            .longOpt(Constants.AUTO_CREATE_PARTITION)
            .hasArg()
            .argName("ARG")
            .desc("auto create target partition if not exists, default "
                  + Constants.DEFAULT_AUTO_CREATE_PARTITION)
            .build());
    opts.addOption(
        Option.builder("ss")
            .longOpt(Constants.STRICT_SCHEMA)
            .hasArg()
            .argName("ARG")
            .desc(
                "specify strict schema mode. If false, extra data will be abandoned and insufficient field will be filled with null. Default "
                + Constants.DEFAULT_STRICT_SCHEMA)
            .build());
    opts.addOption(
        Option.builder("ow")
            .longOpt(Constants.OVERWRITE)
            .hasArg()
            .argName("true | false")
            .desc("overwrite specified table or partition, default: " + Constants.DEFAULT_OVERWRITE)
            .build());
    return opts;
  }