docs: private void open() {
      // Load existing log segments from disk.
      for (JournalSegment<E> segment : loadSegments()) {
        segments.put(segment.descriptor().index(), segment);
      }
  
      // If a segment doesn't already exist, create an initial segment starting at index 1.
      if (!segments.isEmpty()) {
        currentSegment = segments.lastEntry().getValue();
      } else {
        JournalSegmentDescriptor descriptor = JournalSegmentDescriptor.builder()
            .withId(1)
            .withIndex(1)
            .withMaxSegmentSize(maxSegmentSize)
            .withMaxEntries(maxEntriesPerSegment)
            .build();
  
        currentSegment = createSegment(descriptor);
        currentSegment.descriptor().update(System.currentTimeMillis());
  
        segments.put(1L, currentSegment);
      }
    }