dendrite/internal
Player d40221e715
Add SQLite WAL and busy_timeout
SQLite has rather unfortunate defaults for concurrent accesses, leading to database locked errors. https://github.com/matrix-org/dendrite/pull/1290 appears to try to fix some of this, but doesn't appear to cover a concurrent read+write and the errors still happened in large quantities when I joined the dendrite room.

This PR enables WAL for concurrent read+write and much better performance. It also sets busy_timeout to 10 seconds to not immediately fail operations while the database is locked, providing a DB level solution to PR 1290's objective with additional coverage.

I chose this particular location to add the two statements as they should apply to every SQLite DB connection.

From a quick test it looks as if the db locked errors are gone with this change.
2022-08-11 06:39:54 +00:00
..
caching Invalidate lazyLoadCache if we're doing an initial sync (#2623) 2022-08-05 14:27:27 +02:00
eventutil Ristretto cache (#2563) 2022-07-11 14:31:31 +01:00
hooks MSC2836: Threading - part one (#1589) 2020-11-19 11:34:59 +00:00
httputil Rate limiting changes (#2519) 2022-06-07 14:24:04 +01:00
pushgateway Back out matrix-org/dendrite#2421 by restoring http.Clients 2022-05-10 11:08:10 +01:00
pushrules Implement Push Notifications (#1842) 2022-03-03 11:40:53 +00:00
sqlutil Add SQLite WAL and busy_timeout 2022-08-11 06:39:54 +00:00
transactions Implement read receipts (#1528) 2020-11-09 18:46:11 +00:00
log.go Fix linter issues (#2624) 2022-08-05 11:12:41 +02:00
log_unix.go Do not use ioutil as it is deprecated (#2625) 2022-08-05 10:26:59 +01:00
log_windows.go Fix building on Windows (#2008) 2021-11-02 16:50:59 +00:00
mutex.go Add a per-room mutex to federationapi when processing transactions (#1810) 2021-03-30 10:01:32 +01:00
version.go Version 0.9.1 (#2616) 2022-08-03 17:42:13 +01:00