Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Add a unique index to `state_group_edges` to prevent duplicates being ↵ | reivilibre | 2022-05-19 | 1 | -0/+15 |
| | | | | accidentally introduced and the consequential impact to performance. (#12687) | ||||
* | Do not keep going if there are 5 back-to-back background update failures. ↵ | reivilibre | 2022-05-18 | 1 | -0/+8 |
| | | | | (#12781) | ||||
* | Another batch of type annotations (#12726) | David Robertson | 2022-05-13 | 1 | -5/+14 |
| | |||||
* | Add config settings for background update parameters (#11980) | Shay | 2022-03-11 | 1 | -14/+25 |
| | |||||
* | Fix a bug in background updates wherein background updates are never run ↵ | Shay | 2022-03-07 | 1 | -3/+5 |
| | | | | using the default batch size (#12157) | ||||
* | Make background updates controllable via a plugin (#11306) | Erik Johnston | 2021-11-29 | 1 | -23/+169 |
| | | | Co-authored-by: Brendan Abolivier <babolivier@matrix.org> | ||||
* | Lower minumum batch size to 1 for background updates (#11422) | Brendan Abolivier | 2021-11-24 | 1 | -1/+1 |
| | | | Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> | ||||
* | Add an admin API to run background jobs. (#11352) | Dirk Klimpel | 2021-11-19 | 1 | -0/+2 |
| | | | | | | Instead of having admins poke into the database directly. Can currently run jobs to populate stats and to populate the user directory. | ||||
* | Add some background update admin APIs (#11263) | Erik Johnston | 2021-11-08 | 1 | -18/+47 |
| | | | Fixes #11259 | ||||
* | Use inline type hints in `http/federation/`, `storage/` and `util/` (#10381) | Jonathan de Jong | 2021-07-15 | 1 | -9/+7 |
| | |||||
* | Remove redundant "coding: utf-8" lines (#9786) | Jonathan de Jong | 2021-04-14 | 1 | -1/+0 |
| | | | | | | | Part of #9744 Removes all redundant `# -*- coding: utf-8 -*-` lines from files, as python 3 automatically reads source code as utf-8 now. `Signed-off-by: Jonathan de Jong <jonathan@automatia.nl>` | ||||
* | Import HomeServer from the proper module. (#9665) | Patrick Cloke | 2021-03-23 | 1 | -1/+1 |
| | |||||
* | Update black, and run auto formatting over the codebase (#9381) | Eric Eastwood | 2021-02-16 | 1 | -4/+4 |
| | | | | | | | - Update black version to the latest - Run black auto formatting over the codebase - Run autoformatting according to [`docs/code_style.md `](https://github.com/matrix-org/synapse/blob/80d6dc9783aa80886a133756028984dbf8920168/docs/code_style.md) - Update `code_style.md` docs around installing black to use the correct version | ||||
* | Add additional type hints to the storage module. (#8980) | Patrick Cloke | 2020-12-30 | 1 | -47/+64 |
| | |||||
* | Stop sub-classing object (#8249) | Patrick Cloke | 2020-09-04 | 1 | -2/+2 |
| | |||||
* | Convert additional databases to async/await part 3 (#8201) | Patrick Cloke | 2020-09-01 | 1 | -2/+2 |
| | |||||
* | Convert additional database methods to async (select list, search, ↵ | Patrick Cloke | 2020-08-27 | 1 | -4/+5 |
| | | | | insert_many, delete_*) (#8168) | ||||
* | Use the JSON encoder without whitespace in more places. (#8124) | Patrick Cloke | 2020-08-20 | 1 | -3/+2 |
| | |||||
* | Convert misc database code to async (#8087) | Patrick Cloke | 2020-08-14 | 1 | -9/+5 |
| | |||||
* | Rename database classes to make some sense (#8033) | Erik Johnston | 2020-08-05 | 1 | -11/+11 |
| | |||||
* | Consistently use `db_to_json` to convert from database values to JSON ↵ | Patrick Cloke | 2020-07-16 | 1 | -1/+4 |
| | | | | objects. (#7849) | ||||
* | Update docstring per review comments | Richard van der Hoff | 2020-04-03 | 1 | -1/+1 |
| | |||||
* | review comment | Richard van der Hoff | 2020-04-02 | 1 | -1/+1 |
| | |||||
* | Only run one background update at a time | Richard van der Hoff | 2020-03-31 | 1 | -26/+48 |
| | |||||
* | Make do_next_background_update return a bool | Richard van der Hoff | 2020-03-31 | 1 | -7/+5 |
| | | | | returning a None or an int that we don't use is confusing. | ||||
* | Make `has_completed_background_updates` async | Richard van der Hoff | 2020-03-31 | 1 | -4/+3 |
| | | | | (Almost) everywhere that uses it is happy with an awaitable. | ||||
* | Remove unused `start_background_update` | Richard van der Hoff | 2020-03-31 | 1 | -21/+0 |
| | | | | This was only used in a unit test, so let's just inline it in the test. | ||||
* | Clarify list/set/dict/tuple comprehensions and enforce via flake8 (#6957) | Patrick Cloke | 2020-02-21 | 1 | -1/+1 |
| | | | | Ensure good comprehension hygiene using flake8-comprehensions. | ||||
* | Add a background update to clear tombstoned rooms from the directory (#6648) | Richard van der Hoff | 2020-01-07 | 1 | -0/+15 |
| | | | | | | * Add a background update to clear tombstoned rooms from the directory * use the ABC metaclass | ||||
* | Async/await for background updates (#6647) | Richard van der Hoff | 2020-01-07 | 1 | -16/+20 |
| | | | | so that bg update routines can be async | ||||
* | Pass Database into the data store | Erik Johnston | 2019-12-06 | 1 | -1/+1 |
| | |||||
* | Move background update handling out of store | Erik Johnston | 2019-12-05 | 1 | -8/+7 |
| | |||||
* | Move DB pool and helper functions into dedicated Database class | Erik Johnston | 2019-12-05 | 1 | -8/+8 |
| | |||||
* | Remove underscore from SQLBaseStore functions | Erik Johnston | 2019-12-04 | 1 | -7/+7 |
| | |||||
* | Add CI for synapse_port_db (#6140) | Brendan Abolivier | 2019-10-28 | 1 | -3/+6 |
| | | | | | | | | | | | | | | | | | | This adds: * a test sqlite database * a configuration file for the sqlite database * a configuration file for a postgresql database (using the credentials in `.buildkite/docker-compose.pyXX.pgXX.yaml`) as well as a new script named `.buildkite/scripts/test_synapse_port_db.sh` that: 1. installs Synapse 2. updates the test sqlite database to the latest schema and runs background updates on it 3. creates an empty postgresql database 4. run the `synapse_port_db` script to migrate the test sqlite database to the empty postgresql database (with coverage) Step `2` is done via a new script located at `scripts-dev/update_database`. The test sqlite database is extracted from a SyTest run, so that it can be considered as an actual homeserver's database with actual data in it. | ||||
* | Merge branch 'develop' of github.com:matrix-org/synapse into ↵ | Erik Johnston | 2019-09-25 | 1 | -1/+1 |
|\ | | | | | | | erikj/cleanup_user_ips_2 | ||||
| * | Fix logging | Brendan Abolivier | 2019-09-24 | 1 | -1/+1 |
| | | |||||
* | | Review comments | Erik Johnston | 2019-09-25 | 1 | -4/+1 |
| | | |||||
* | | Add has_completed_background_update | Erik Johnston | 2019-09-24 | 1 | -1/+24 |
|/ | | | | This allows checking if a specific background update has completed. | ||||
* | Replace returnValue with return (#5736) | Amber Brown | 2019-07-23 | 1 | -10/+10 |
| | |||||
* | Run Black. (#5482) | Amber Brown | 2019-06-20 | 1 | -1/+1 |
| | |||||
* | Run black on the rest of the storage module (#4996) | Amber Brown | 2019-04-03 | 1 | -15/+20 |
| | |||||
* | Migrate the user directory initial population to a background task (#4864) | Amber Brown | 2019-03-19 | 1 | -2/+6 |
| | |||||
* | Fix typos | Andrew Morgan | 2019-01-22 | 1 | -1/+1 |
| | |||||
* | Run things as background processes | Richard van der Hoff | 2018-07-18 | 1 | -2/+8 |
| | | | | | | | | This fixes #3518, and ensures that we get useful logs and metrics for lots of things that happen in the background. (There are certainly more things that happen in the background; these are just the common ones I've found running a single-process synapse locally). | ||||
* | run isort | Amber Brown | 2018-07-09 | 1 | -5/+5 |
| | |||||
* | Attempt to be more performant on PyPy (#3462) | Amber Brown | 2018-06-28 | 1 | -1/+2 |
| | |||||
* | Pass around the reactor explicitly (#3385) | Amber Brown | 2018-06-22 | 1 | -2/+1 |
| | |||||
* | Merge branch 'master' of github.com:matrix-org/synapse into develop | Erik Johnston | 2018-03-19 | 1 | -1/+1 |
|\ | |||||
| * | Replace ujson with simplejson | Erik Johnston | 2018-03-15 | 1 | -1/+1 |
| | | |||||
* | | Reinstate event_search_postgres_gist handler | Richard van der Hoff | 2018-02-02 | 1 | -0/+19 |
|/ | | | | People may have queued updates for this, so we can't just delete it. | ||||
* | Check database in has_completed_background_updates | Richard van der Hoff | 2017-11-22 | 1 | -2/+25 |
| | | | | so that the right thing happens on workers. | ||||
* | Fix error on sqlite 3.7 | Richard van der Hoff | 2017-11-21 | 1 | -1/+11 |
| | | | | | | | | | | | Create the url_cache index on local_media_repository as a background update, so that we can detect whether we are on sqlite or not and create a partial or complete index accordingly. To avoid running the cleanup job before we have built the index, add a bailout which will defer the cleanup if the bg updates are still running. Fixes https://github.com/matrix-org/synapse/issues/2572. | ||||
* | Make __init__ consitstent across Store heirarchy | Richard van der Hoff | 2017-11-13 | 1 | -2/+2 |
| | | | | | | Add db_conn parameters to the `__init__` methods of the *Store classes, so that they are all consistent, which makes the multiple inheritance work correctly (and so that we can later extract mixins which can be used in the slavedstores) | ||||
* | replace 'except:' with 'except Exception:' | Richard van der Hoff | 2017-10-23 | 1 | -1/+1 |
| | | | | what could possibly go wrong | ||||
* | Don't create event_search index on sqlite | Richard van der Hoff | 2017-05-11 | 1 | -3/+10 |
| | | | | ... because the table is virtual | ||||
* | Add an index to event_search | Richard van der Hoff | 2017-05-11 | 1 | -3/+7 |
| | | | | - to make the purge API quicker | ||||
* | Fix bgupdate error if index already exists (#2167) | Richard van der Hoff | 2017-04-27 | 1 | -30/+53 |
| | | | | | | | | | When creating a new table index in the background, guard against it existing already. Fixes https://github.com/matrix-org/synapse/issues/2135. Also, make sure we restore the autocommit flag when we're done, otherwise we get more failures from other operations later on. Fixes https://github.com/matrix-org/synapse/issues/1890 (hopefully). | ||||
* | Remove broken use of clock.call_later | Richard van der Hoff | 2017-03-18 | 1 | -12/+3 |
| | | | | | | | | | background_updates was using `call_later` in a way that leaked the logcontext into the reactor. We could have rewritten it to do it properly, but given that we weren't using the fancier facilities provided by `call_later`, we might as well just use `async.sleep`, which does the logcontext stuff properly. | ||||
* | Add WHERE clause support to index creation | Erik Johnston | 2016-09-12 | 1 | -9/+15 |
| | |||||
* | Reindex state_groups_state after pruning | Erik Johnston | 2016-09-08 | 1 | -2/+4 |
| | |||||
* | fix: defer.returnValue takes one argument | Mark Haines | 2016-07-25 | 1 | -1/+1 |
| | |||||
* | background updates: fix assert again | Richard van der Hoff | 2016-07-25 | 1 | -1/+1 |
| | |||||
* | background updates: Fix assertion to do something | Richard van der Hoff | 2016-07-25 | 1 | -2/+2 |
| | |||||
* | Fix background_update tests | Richard van der Hoff | 2016-07-25 | 1 | -7/+20 |
| | | | | | | A bit of a cleanup for background_updates, and make sure that the real background updates have run before we start the unit tests, so that they don't interfere with the tests. | ||||
* | Create index on user_ips in the background | Richard van der Hoff | 2016-07-22 | 1 | -7/+66 |
| | | | | | | | | user_ips is kinda big, so really we want to add the index in the background once we're running. Replace the schema delta with one which will do that. I've done this in a way that's reasonably easy to reuse as there a few other indexes I need, and I don't suppose they will be the last. | ||||
* | Simplify query and handle finishing correctly | Erik Johnston | 2016-04-22 | 1 | -1/+2 |
| | |||||
* | copyrights | Matthew Hodgson | 2016-01-07 | 1 | -1/+1 |
| | |||||
* | Fix the background update | Mark Haines | 2015-11-11 | 1 | -5/+8 |
| | |||||
* | Run the background updates when starting synapse. | Mark Haines | 2015-11-10 | 1 | -7/+50 |
| | |||||
* | Add storage module for tracking background updates. | Mark Haines | 2015-11-09 | 1 | -0/+210 |
The progress for each background update is stored as a JSON blob in the database. Each background update is broken up into separate batches. The batch size is automatically tuned to try avoid blocking single threaded databases for too long. |