Open MarcAntoine-Arnaud opened 1 month ago
After some research, I have found https://stackoverflow.com/questions/72915138/how-to-fix-database-is-locked-when-no-concurrent-threads-are-involved-golang
where it's mentioned to limit to 1 connection, by changing that line with const DB_MAX_CONNECTIONS: u32 = 1;
I didn't get the issue.
I think it's one limit of using sqlite, but maybe enough to start.
Interesting, I never has this issue when publishing. Originally, the max number of connections was 1 and it was relaxed recently in 903e4710cca5a4709e36a51f7a3fc1e28b153918. This failed to account for concurrent read/write. Potential fixes are explained in https://github.com/launchbadge/sqlx/issues/451
I got a database lock on server side during the execution of command on my laptop:
cargo publish --registry luminvent --allow-dirty -v