gristlabs_grist-core/app/gen-server
Paul Fitzpatrick ff77ecc6c6 (core) deal with SQLITE_BUSY: database is locked during tests
Summary:
During testing, and in some dev configurations, we make connections to
the Grist home database from multiple processes, and store it in Sqlite.
This is a situation prone to file locks in Sqlite. We set a busy_timeout
parameter to help, but transactions may still fail immediately. This
diff adds retries to our patch of TypeORM for Sqlite transactions
(which without the patch are already flakey for other reasons
https://github.com/typeorm/typeorm/issues/1884#issuecomment-380767213).

Without this change, I can tickly SQLITE_BUSY problems fairly
reliably with the DocApi tests. With this change, I can't so far.

This change should not affect deployments of our SaaS (which use
Postgres for home db) or grist-core/grist-ee (which access home
db from a single process in default configuration).

Test Plan: repeated running of DocApi tests

Reviewers: dsagal

Reviewed By: dsagal

Subscribers: dsagal

Differential Revision: https://phab.getgrist.com/D3466
2022-06-03 15:51:59 -04:00
..
entity (core) Show usage banners in doc menu of free team sites 2022-05-26 15:01:35 -07:00
lib (core) deal with SQLITE_BUSY: database is locked during tests 2022-06-03 15:51:59 -04:00
migration (core) Adding GristConnect login system 2022-05-18 20:28:25 +02:00
ApiServer.ts (core) Add API endpoint to get site usage summary 2022-05-16 11:16:19 -07:00
sqlUtils.ts (core) fix bug where sharing doc with everyone@ as viewer made it unlisted for site viewers 2021-10-28 12:48:31 -04:00