fix(quiz): expire rooms after an hour of inactivity #12
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/quiz-idle-ttl"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Quiz rooms now expire after 1 hour without activity instead of 24h from creation. A join, answer or host action resets the clock, so a long talk is never cut off, and an abandoned room is gone within the hour.
Session.Activeis updated inPersist, which runs after every change, and is saved in the snapshot. Older snapshots without it fall back toCreated.ExpireandRestoreuse idle time; Redis keys get a fresh 1h TTL on every write.