Changes: 1. Added dirty flag to WebDavVersioning to track unsaved changes 2. Modified create_version() to only mark dirty=true instead of immediate save_index() 3. Added flush() method to save dirty index periodically 4. Added background thread in server.rs to flush every 60 seconds 5. Async index loading on startup (spawn thread to avoid blocking OPTIONS/PROPFIND) Expected performance: - PUT operations: still fast (dirty flag only, no save_index() blocking) - Index persistence: flush every 60 seconds (or on shutdown) - OPTIONS/PROPFIND: no blocking (async index loading) Test results: - PUT (31B): 0.053s (53ms) ✅ - Index loading: async thread started ✅ - Flush thread: started but blocked by launchd auto-restart ⚠️ Next: Test flush thread in production environment (without launchd)
2 lines
19 B
Plaintext
2 lines
19 B
Plaintext
Small test content
|