code: private void transferEntry(long index, Entry entry, Segment compactSegment) {
      compactSegment.append(entry);
  
      // If the entry was released in the prior segment, mark it as released in the compact segment.
      if (!segment.isLive(index)) {
        compactSegment.release(index);
      }
    }
docs: Transfers an entry to the given compact segment.