In ContentProvider+File we use synchronous file I/O (Data(contentsOf:)) inside async handlers. For a low-traffic personal site behind Cloudflare, this may be fine.
If we want to be rigorous with non-blocking I/O, consider:
• Preloading content at startup into memory / a cache
• NIO’s non-blocking file I/O if we expect growth or want to avoid blocking threads
In ContentProvider+File we use synchronous file I/O (
Data(contentsOf:)) inside async handlers. For a low-traffic personal site behind Cloudflare, this may be fine.If we want to be rigorous with non-blocking I/O, consider:
• Preloading content at startup into memory / a cache
• NIO’s non-blocking file I/O if we expect growth or want to avoid blocking threads