SQLite is embedded in the main thread same as the HTTP server. I noticed some requests dropping and because the queries have become more complex I figured it has to do with SQLite blocking for too much time. Moving it to a Worker makes the DB asynchronous and bypass this problem.
Good work! What motivated the refactor exactly? I'm not familiar at all with Worker