-
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 5 replies
-
hello. Try to solve this issue without |
Beta Was this translation helpful? Give feedback.
-
// 启用 SQLite 的线程安全模式:SQLITE_CONFIG_SERIALIZED |
Beta Was this translation helpful? Give feedback.
-
Thank you. Do you have any good suggestions for the encapsulation of orm in the project? I am now piling them all together and then exposing getStorage to the outside world. Thank you very much. |
Beta Was this translation helpful? Give feedback.
-
Many thanks 万分感谢 |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
hello. Try to solve this issue without
sqlite_orm
but with rawlibsqlite3
. The issue will persist cause one cannot write in different threads simultaneously. One can read from different threads simultaneously for sure for write can be performed only by one thread one time. So if you have a bunch of threads and you expect all of them to write to SQLite you need to either add mutex and check that performance is not reduced or make only one writing thread and pass all write requests to it.