ByteBuffer encode() {
            ByteBuffer buffer = ByteBuffer.allocate(HEADER_SIZE);
            buffer.put(MAGIC);
            buffer.put(MAGIC);
            buffer.putLong(this.firstLogIndex);
            buffer.putLong(RESERVED_FLAG);
            BufferUtils.flip(buffer);
            return buffer;
        }
Segment file header.
@author boyan(boyan@antfin.com)
jraft-core/src/main/java/com/alipay/sofa/jraft/storage/log/SegmentFile.java