code: public WriteResponse write (String record) throws IOException {
      recordsAttempted.mark();
      String encoded = encodeRecord(record);
      int returnCode = request (encoded);
      recordsSuccess.mark();
      bytesWritten.mark(encoded.length());
      return WRITE_RESPONSE_WRAPPER.wrap(returnCode);
    }
docs: Write a single record to eventhub