To prevent data loss or corruption, the disk-backed queue should always creates and writes to a new segment file after a process restart. This avoids accidentally overwriting existing segment files when the previous state was not fully flushed or closed properly.
It also simplifies recovery and ensures better durability guarantees across restarts.