.setTerm(log.currentTerm())
.setLeaderId(log.self().toString())
.setPrevLogIndex(result.lastLogIndex())
.setPrevLogTerm(result.lastLogTerm())
.setCommitIndex(log.commitIndex())
.addAllEntries(result.entries())
.build();
LOGGER.debug("Sending update to {} prevLogIndex: {}, prevLogTerm: {}, nr. of entries {}", remote, result.lastLogIndex(),
result.lastLogTerm(), result.entries().size());