losfair / mvsqlite

Distributed, MVCC SQLite that runs on FoundationDB.
https://github.com/losfair/mvsqlite/wiki
Apache License 2.0
1.35k stars 38 forks source link

Please update the Cargo.lock for moka cache to v0.9.8 #117

Open tatsuya6502 opened 12 months ago

tatsuya6502 commented 12 months ago

Hi. Currently, moka cache version is pinned to v0.9.4 by the Cargo.lock file: https://github.com/losfair/mvsqlite/blob/f2117d3c2c9111e5c617850af2a6989bb639e656/Cargo.lock#L1178-L1179

Please upgrade it to v0.9.8 or the latest v0.11.2.

We found a critical bug that will cause a segfault in a corner case: https://github.com/moka-rs/moka/issues/281#issuecomment-1616445598. It is fixed for v0.11.0 and then backported to v0.9.8 and v0.10.3.

tatsuya6502 commented 12 months ago

A pull request is already opened by Renovate: https://github.com/losfair/mvsqlite/pull/100

tatsuya6502 commented 12 months ago

I checked the usage of moka in mvSQLite, and I think it is okay to continue using v0.9.4.

I believe the bug will be triggered only when weigher (doc) is set, and all other timings in different threads are met. I found mvSQLite does not set weigher to any Caches.

https://github.com/losfair/mvsqlite/blob/ec0cb13a9657ae0f503a2a289f5da78ac90fa4d2/mvstore/src/server.rs#L225-L247

https://github.com/losfair/mvsqlite/blob/ec0cb13a9657ae0f503a2a289f5da78ac90fa4d2/mvstore/src/metadata.rs#L43-L46

Anyway, I would still encourage to upgrade moka to v0.9.8 or the latest v0.11.2 just for sure.