Commit Graph

106 Commits

Author SHA1 Message Date
shortcutme 2e9cff928c
Skip commit if already commiting 2020-01-28 16:58:14 +01:00
shortcutme 835174270e
Less wait for closing cursors 2020-01-22 16:36:52 +01:00
shortcutme 62a2ec7254
Make sure to commit before vacuum 2020-01-22 16:36:33 +01:00
shortcutme 71d32d7414
Less slow query loggin 2019-12-31 12:45:36 +01:00
shortcutme c161140a90
Add locking for db cursor 2019-12-18 16:43:46 +01:00
shortcutme 98c98fbac7
Thread safe method to create directory for db 2019-12-17 15:02:18 +01:00
shortcutme 9b1f6337c3
Wait for cursor finish on db close 2019-12-17 15:02:04 +01:00
shortcutme 0839fdfc5e
Add reason for db close 2019-12-17 14:35:49 +01:00
shortcutme dca1dcdd2d
Use always active connection in DbCursor 2019-12-17 14:28:52 +01:00
shortcutme 23f851343f
Fix exception when params is an iterator 2019-12-04 17:15:08 +01:00
shortcutme 5ce1782d05
Change journal and foreign keys mode on db connect 2019-12-04 17:14:50 +01:00
shortcutme 1a17645e93
Remove unnecessary import 2019-11-30 02:14:08 +01:00
shortcutme 5fba850d74
Don't close connection if it's already closed 2019-11-30 02:13:58 +01:00
shortcutme bd90e0ce52
Add Db id to logging identifier 2019-11-30 02:13:39 +01:00
shortcutme c24cfa721b
Lock db while connecting 2019-11-30 02:13:17 +01:00
shortcutme 1670d96908
Execute db commit in separate thread 2019-11-30 02:12:33 +01:00
shortcutme ec3c44c5b3
Use ThreadPool lock in Db 2019-11-30 02:11:34 +01:00
shortcutme 12bfad8fe6
Don't execute query while commiting 2019-11-30 02:11:11 +01:00
shortcutme 594edc6e9a
Commit after executemany 2019-11-30 02:10:40 +01:00
shortcutme 99304a09ca
Log long db queries 2019-11-30 02:10:11 +01:00
shortcutme fca9db7972
Try fix Recursive use of cursors ProgrammingError by creating new cursor for every execute and move Lock to db 2019-11-27 03:07:08 +01:00
d9xr92 89e8fd3d3a potential fix for #2323 (#2324)
* potential fix for #2323

* Update DbCursor.py

* replaced RLock with Lock
2019-11-23 13:22:36 +01:00
shortcutme 8f27f50b34
Log SQL statements in progress as warning 2019-11-19 02:09:36 +01:00
shortcutme 96e7fbdca1
Don't try to commit if no db connection 2019-11-19 02:08:30 +01:00
shortcutme 0531d47721
Fix shutdown errors on macOS 2019-10-24 03:08:45 +02:00
shortcutme 608a411d97
Db table rebuild as debug message 2019-10-16 15:43:28 +02:00
shortcutme f4f0e2afa8
Allow like parameters in database queries 2019-07-10 03:14:09 +02:00
Lola Dam 753396ac0c Try and catch block for dbRebuild (#2047)
* Try and catch block for dbRebuild

* Use self.log.error and not logging

* Use self.log.error and not logging in SiteStorage also

* Check if the rebuild is working
2019-06-23 14:21:50 +02:00
Lola Dam 9cda561091 Show error message when db failed to rebuild (#2043)
* Show error message when db failed to rebuild; fix #1908;

* Forgot file
2019-06-04 13:54:35 +02:00
shortcutme 7bef78e10f
Fix newsfeed sql query with many parameters 2019-04-29 16:44:13 +02:00
shortcutme 446641c31c
Always commit before Db VACUUM 2019-04-15 22:11:44 +02:00
radfish f6e3a74567 [setuptools packaging] access modules via imports (#1969) 2019-04-15 12:31:33 +02:00
shortcutme 8c52038671
Switch to WAL mode as it's faster on older sqlite 2019-03-20 00:49:51 +01:00
shortcutme 7aff97b6ff
Fix loading json files to db on Python 3.5 2019-03-20 00:49:27 +01:00
shortcutme c88152cac2
Use shared cursor where possible 2019-03-18 03:36:44 +01:00
shortcutme 61c72ac3ea
Fix SQLite concurrency errors 2019-03-18 03:36:12 +01:00
shortcutme 84c39f3baa
Less sensitive db progress handler 2019-03-18 03:33:51 +01:00
shortcutme 7d6ef195fd
Don't allow to run db on different thread 2019-03-18 03:33:28 +01:00
shortcutme 52ac972332
Keep need commit status if commit failed 2019-03-18 03:33:06 +01:00
shortcutme 9aa599f9d2
Close and commit all db at exit 2019-03-18 03:32:42 +01:00
shortcutme a1b5dad1c8
New Db connection type to avoid corruption 2019-03-16 02:40:32 +01:00
shortcutme 4fe4d0a7e7
BEGIN / END no longer necessary as there is no autocommit in new db module 2019-03-16 02:18:53 +01:00
shortcutme b0b9a4d33c
Change to Python3 coding style 2019-03-15 21:06:59 +01:00
shortcutme 13c453d610
Embed query values if more than 100 specified 2019-01-26 20:40:34 +01:00
shortcutme 47316741c1
Allow only CREATE in indexes 2018-12-15 17:48:19 +01:00
shortcutme 4195a72621
Only create default json table if it's not defined in dbschema 2018-11-21 03:31:12 +01:00
shortcutme 8cf30893f2
Don't close idle db connection during rebuild 2018-11-08 01:20:33 +01:00
shortcutme f05c7ffbfa
Fix parsing invalid files for db 2018-10-30 04:43:21 +01:00
Christian Seibold 413b6cc43c
Import Debug in Db/Db.py 2018-10-20 01:58:35 -05:00
shortcutme 1fc364fa07
Remove unused lines from dbCursor 2018-10-15 13:01:44 +02:00