Repository navigation
Release b237
fix: improve database rotation logic to use directory scanning
Previous implementation used metadata.created() which fails on most Linux
filesystems that don't store file creation time. This caused the rotation
to never trigger.
New logic:
- Scan the logs directory for existing archive files
- Check if any archive matches the current month pattern (record_YYYYMM)
- Only rotate if no archive exists for the current month
This is more reliable across different filesystems and ensures rotation
happens exactly once per month.