@Override
  public String format(LogRecord record) {
    long recordMillis = record.getMillis(), startedMillis = getStartedMillis();
    StringBuilder sb = new StringBuilder();

    if (withDateTime) {
      LocalDateTime date = LocalDateTime.ofInstant(Instant.ofEpochMilli(recordMillis), ZoneId.systemDefault());
      sb.append(date.getYear());
      sb.append('-');
      appendWithPadding(sb, Integer.toString(date.getMonthValue()), 2, '0');
      sb.append('-');
      appendWithPadding(sb, Integer.toString(date.getDayOfMonth()), 2, '0');
      sb.append(' ');
      appendWithPadding(sb, Integer.toString(date.getHour()), 2, '0');
      sb.append(':');
      appendWithPadding(sb, Integer.toString(date.getMinute()), 2, '0');
      sb.append(':');
      appendWithPadding(sb, Integer.toString(date.getSecond()), 2, '0');
      sb.append(',');
      appendWithPadding(sb, Long.toString(recordMillis % 1000), 3, '0');
      sb.append(' ');
    }

    sb.append('[');
    appendWithPadding(sb, startedMillis == 0 ? "-------" : String.valueOf(recordMillis - startedMillis), 7, ' ');
    sb.append("] ");

    appendWithPadding(sb, LogLevel.getPrettyLevelName(record.getLevel()), 6, ' ');

    sb.append(" - ")
      .append(smartAbbreviate(record.getLoggerName()))
      .append(" - ")
      .append(formatMessage(record))
      .append(LINE_SEPARATOR);

    if (record.getThrown() != null) {
      appendThrowable(record.getThrown(), sb);
    }

    return sb.toString();
  }
@Override
  public String format(LogRecord record)