public long appendVotersRecord(
        VotersRecord voters,
        long currentTimestamp
    ) {
        return appendControlMessages((baseOffset, epoch, compression, buffer) ->
            MemoryRecords.withVotersRecord(
                baseOffset,
                currentTimestamp,
                epoch,
                buffer,
                voters
            )
        );
    }
Append a {@link VotersRecord} record to the batch

@param voters the record to append
@param currentTimestamp the current time in milliseconds
@return the last of offset of the records created
@throws IllegalStateException on failure to allocate a buffer for the record
raft/src/main/java/org/apache/kafka/raft/internals/BatchAccumulator.java