code: private synchronized void updateBytesWrittenMeter() {
      if (this.bytesWrittenMeter.isPresent()) {
        try {
          this.bytesWrittenMeter.get().mark(bytesWritten() - this.bytesWrittenMeter.get().getCount());
        } catch (IOException e) {
          log.error("Cannot get bytesWritten for DataWriter, will not update " + this.bytesWrittenMeter.get().toString(),
              e);
        }
      }
    }
docs: Update the {@link #bytesWrittenMeter} using the {@link DataWriter#bytesWritten()} method.