public void setData(final ByteBuffer data) {
        Requires.requireNonNull(data, "data should not be null, you can use LogEntry.EMPTY_DATA instead.");
        this.data = data;
    }
Creates a task with data/done/expectedTerm.
jraft-core/src/main/java/com/alipay/sofa/jraft/entity/Task.java