- Oct 19, 2020
-
-
Richard van der Hoff authored
We need to make sure we are readu for the `set_cache_factor` callback.
-
Richard van der Hoff authored
* Add `DeferredCache.get_immediate` method A bunch of things that are currently calling `DeferredCache.get` are only really interested in the result if it's completed. We can optimise and simplify this case. * Remove unused 'default' parameter to DeferredCache.get() * another get_immediate instance
-
Patrick Cloke authored
-
- Oct 16, 2020
-
-
Richard van der Hoff authored
rather than have everything that instantiates an LruCache manage metrics separately, have LruCache do it itself.
-
- Oct 15, 2020
-
-
Jonathan de Jong authored
This implements a more standard API for instantiating a homeserver and moves some of the dependency injection into the test suite. More concretely this stops using `setattr` on all `kwargs` passed to `HomeServer`.
-
Will Hunt authored
Optionally sends typing, presence, and read receipt information to appservices.
-
- Oct 14, 2020
-
-
Richard van der Hoff authored
-
Richard van der Hoff authored
-
Richard van der Hoff authored
-
Erik Johnston authored
These are tests for #8439
-
Erik Johnston authored
* Fix outbound federaion with multiple event persisters. We incorrectly notified federation senders that the minimum persisted stream position had advanced when we got an `RDATA` from an event persister. Notifying of federation senders already correctly happens in the notifier, so we just delete the offending line. * Change some interfaces to use RoomStreamToken. By enforcing use of `RoomStreamTokens` we make it less likely that people pass in random ints that they got from somewhere random.
-
- Oct 13, 2020
-
-
Richard van der Hoff authored
Update `EventCreationHandler.create_event` to accept an auth_events param, and use it in `_locally_reject_invite` instead of reinventing the wheel.
-
Richard van der Hoff authored
-
Richard van der Hoff authored
Support returning a new event dict from `check_event_allowed`.
-
Richard van der Hoff authored
this is always the same as requester.access_token_id.
-
Patrick Cloke authored
-
Erik Johnston authored
Should fix #3365.
-
- Oct 12, 2020
-
-
Erik Johnston authored
Currently background proccesses stream the events stream use the "minimum persisted position" (i.e. `get_current_token()`) rather than the vector clock style tokens. This is broadly fine as it doesn't matter if the background processes lag a small amount. However, in extreme cases (i.e. SyTests) where we only write to one event persister the background processes will never make progress. This PR changes it so that the `MultiWriterIDGenerator` keeps the current position of a given instance as up to date as possible (i.e using the latest token it sees if its not in the process of persisting anything), and then periodically announces that over replication. This then allows the "minimum persisted position" to advance, albeit with a small lag.
-
- Oct 09, 2020
-
-
Patrick Cloke authored
-
Richard van der Hoff authored
This could, very occasionally, cause: ``` tests.test_visibility.FilterEventsForServerTestCase.test_large_room =============================================================================== [ERROR] Traceback (most recent call last): File "/src/tests/rest/media/v1/test_media_storage.py", line 86, in test_ensure_media_is_in_local_cache self.wait_on_thread(x) File "/src/tests/unittest.py", line 296, in wait_on_thread self.reactor.advance(0.01) File "/src/.tox/py35/lib/python3.5/site-packages/twisted/internet/task.py", line 826, in advance self._sortCalls() File "/src/.tox/py35/lib/python3.5/site-packages/twisted/internet/task.py", line 787, in _sortCalls self.calls.sort(key=lambda a: a.getTime()) builtins.ValueError: list modified during sort tests.rest.media.v1.test_media_storage.MediaStorageTests.test_ensure_media_is_in_local_cache ```
-
Andrew Morgan authored
This PR allows Synapse modules making use of the `ModuleApi` to create and send non-membership events into a room. This can useful to have modules send messages, or change power levels in a room etc. Note that they must send event through a user that's already in the room. The non-membership event limitation is currently arbitrary, as it's another chunk of work and not necessary at the moment.
-
Patrick Cloke authored
All handlers now available via get_*_handler() methods on the HomeServer.
-
- Oct 08, 2020
-
-
Hubert Chathi authored
-
- Oct 07, 2020
-
-
Erik Johnston authored
We call `_update_stream_positions_table_txn` a lot, which is an UPSERT that can conflict in `REPEATABLE READ` isolation level. Instead of doing a transaction consisting of a single query we may as well run it outside of a transaction.
-
Erik Johnston authored
We call `_update_stream_positions_table_txn` a lot, which is an UPSERT that can conflict in `REPEATABLE READ` isolation level. Instead of doing a transaction consisting of a single query we may as well run it outside of a transaction.
-
Hubert Chathi authored
This allows a user to store an offline device on the server and then restore it at a subsequent login.
-
Richard van der Hoff authored
Lots of different module apis is not easy to maintain. Rather than adding yet another ModuleApi(hs, hs.get_auth_handler()) incantation, first add an hs.get_module_api() method and use it where possible.
-
- Oct 06, 2020
-
-
Hubert Chathi authored
-
Richard van der Hoff authored
* Optimise and test state fetching for 3p event rules Getting all the events at once is much more efficient than getting them individually * Test that 3p event rules can modify events
-
- Oct 05, 2020
-
-
Richard van der Hoff authored
PR #8292 tried to maintain backwards compat with modules which don't provide a `check_visibility_can_be_modified` method, but the tests weren't being run, and the check didn't work.
-
Richard van der Hoff authored
This is now redundant, and we can just call `handle_new_client_event` directly.
-
Andrew Morgan authored
This PR allows `ThirdPartyEventRules` modules to view, manipulate and block changes to the state of whether a room is published in the public rooms directory. While the idea of whether a room is in the public rooms list is not kept within an event in the room, `ThirdPartyEventRules` generally deal with controlling which modifications can happen to a room. Public rooms fits within that idea, even if its toggle state isn't controlled through a state event.
- Oct 02, 2020
-
-
Erik Johnston authored
This is so we can tell what is going on when things are taking a while to start up. The main change here is to ensure that transactions that are created during startup get correctly logged like normal transactions.
-
Erik Johnston authored
-
Patrick Cloke authored
-
Erik Johnston authored
-
- Oct 01, 2020
-
-
BBBSnowball authored
This allows for connecting to certain IdPs, e.g. GitLab.
-
- Sep 30, 2020
-
-
Erik Johnston authored
The idea is that in future tokens will encode a mapping of instance to position. However, we don't want to include the full instance name in the string representation, so instead we'll have a mapping between instance name and an immutable integer ID in the DB that we can use instead. We'll then do the lookup when we serialize/deserialize the token (we could alternatively pass around an `Instance` type that includes both the name and ID, but that turns out to be a lot more invasive).
-
Patrick Cloke authored
-