@VisibleForTesting
  public static TagConfiguration parseTagConfiguration(Map<String, String> tableProperties) {
    TagConfiguration tagConfig = new TagConfiguration();
    tagConfig.setAutoCreateTag(
        CompatiblePropertyUtil.propertyAsBoolean(
            tableProperties,
            TableProperties.ENABLE_AUTO_CREATE_TAG,
            TableProperties.ENABLE_AUTO_CREATE_TAG_DEFAULT));
    tagConfig.setTriggerPeriod(
        TagConfiguration.Period.valueOf(
            CompatiblePropertyUtil.propertyAsString(
                    tableProperties,
                    TableProperties.AUTO_CREATE_TAG_TRIGGER_PERIOD,
                    TableProperties.AUTO_CREATE_TAG_TRIGGER_PERIOD_DEFAULT)
                .toUpperCase(Locale.ROOT)));

    String defaultFormat;
    switch (tagConfig.getTriggerPeriod()) {
      case DAILY:
        defaultFormat = TableProperties.AUTO_CREATE_TAG_FORMAT_DAILY_DEFAULT;
        break;
      case HOURLY:
        defaultFormat = TableProperties.AUTO_CREATE_TAG_FORMAT_HOURLY_DEFAULT;
        break;
      default:
        throw new IllegalArgumentException(
            "Unsupported trigger period: " + tagConfig.getTriggerPeriod());
    }
    tagConfig.setTagFormat(
        CompatiblePropertyUtil.propertyAsString(
            tableProperties, TableProperties.AUTO_CREATE_TAG_FORMAT, defaultFormat));
    tagConfig.setTriggerOffsetMinutes(
        CompatiblePropertyUtil.propertyAsInt(
            tableProperties,
            TableProperties.AUTO_CREATE_TAG_TRIGGER_OFFSET_MINUTES,
            TableProperties.AUTO_CREATE_TAG_TRIGGER_OFFSET_MINUTES_DEFAULT));
    tagConfig.setMaxDelayMinutes(
        CompatiblePropertyUtil.propertyAsInt(
            tableProperties,
            TableProperties.AUTO_CREATE_TAG_MAX_DELAY_MINUTES,
            TableProperties.AUTO_CREATE_TAG_MAX_DELAY_MINUTES_DEFAULT));
    tagConfig.setTagMaxAgeMs(
        CompatiblePropertyUtil.propertyAsLong(
            tableProperties,
            TableProperties.AUTO_CREATE_TAG_MAX_AGE_MS,
            TableProperties.AUTO_CREATE_TAG_MAX_AGE_MS_DEFAULT));
    return tagConfig;
  }
Parse tag configuration from table properties

@param tableProperties table properties
@return table tag configuration
amoro-ams/src/main/java/org/apache/amoro/server/table/TableConfigurations.java