docs: String writeDocument(Meter meter, Consumer<StringBuilder> consumer) {
          StringBuilder sb = new StringBuilder(indexLine);
          String timestamp = TIMESTAMP_FORMATTER.format(Instant.ofEpochMilli(config().clock().wallTime()));
          String name = getConventionName(meter.getId());
          String type = meter.getId().getType().toString().toLowerCase();
          sb.append("{\"").append(config.timestampFieldName()).append("\":\"").append(timestamp).append('"')
                  .append(",\"name\":\"").append(escapeJson(name)).append('"')
                  .append(",\"type\":\"").append(type).append('"');
  
          List<Tag> tags = getConventionTags(meter.getId());
          for (Tag tag : tags) {
              sb.append(",\"").append(escapeJson(tag.getKey())).append("\":\"")
                      .append(escapeJson(tag.getValue())).append('"');
          }
  
          consumer.accept(sb);
          sb.append("}");
  
          return sb.toString();
      }