3 ms·
Would you share details about the architecture of such systems? Specially on how to deal with concurrent writes on SQLite.
by hu3 6y ago
Would you share details about the architecture of such systems?
Specially on how to deal with concurrent writes on SQLite.
- isodev 6y agoI avoid concurrent writes as much as possible. With this approach, services are usually separated (e.g. microservices or a monolith with several db clients) and use several sqlite db files. For example, users.db, receipts.db, posts.db etc. For data which is frequently accessed, it really helps to consider caching (e.g. HTTP). I realise of course this won't scale infinitely so I usually make use of ORMs (e.g. GORM for Go/Gin or Diesel for Rust/Actix) just in case the SQL engine would need to change (so I don't have to rewrite queries etc). I haven't had the need to do so yet.