docs: public Optional<CommitLog> commitAndGetLogs() throws InvalidKBException {
          if (isClosed()) {
              return Optional.empty();
          }
          try {
              return commitWithLogs();
          } finally {
              String closeMessage = ErrorMessage.TX_CLOSED_ON_ACTION.getMessage("committed", keyspace());
              closeTransaction(closeMessage);
          }
      }