summary refs log tree commit diff
path: root/synapse/replication/http (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Add rate-limiting on registration (#4735)Brendan Abolivier2019-03-051-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Rate-limiting for registration * Add unit test for registration rate limiting * Add config parameters for rate limiting on auth endpoints * Doc * Fix doc of rate limiting function Co-Authored-By: babolivier <contact@brendanabolivier.com> * Incorporate review * Fix config parsing * Fix linting errors * Set default config for auth rate limiting * Fix tests * Add changelog * Advance reactor instead of mocked clock * Move parameters to registration specific config and give them more sensible default values * Remove unused config options * Don't mock the rate limiter un MAU tests * Rename _register_with_store into register_with_store * Make CI happy * Remove unused import * Update sample config * Fix ratelimiting test for py2 * Add non-guest test
* Fix registration on workers (#4682)Erik Johnston2019-02-203-3/+58
| | | | | | | | | | * Move RegistrationHandler init to HomeServer * Move post registration actions to RegistrationHandler * Add post regisration replication endpoint * Newsfile
* Move register_device into handlerErik Johnston2019-02-181-14/+3
|
* Split out registration to workerErik Johnston2019-02-183-1/+179
| | | | | | | | This allows registration to be handled by a worker, though the actual write to the database still happens on master. Note: due to the in-memory session map all registration requests must be handled by the same worker.
* Fix replication for room v3 (#4523)Erik Johnston2019-01-301-1/+4
| | | | | | | | | * Fix replication for room v3 We were not correctly quoting the path fragments over http replication, which meant that it exploded when the event IDs had a slash in them * Newsfile
* Fix receiving events from federation via a workerErik Johnston2019-01-291-1/+1
| | | | This bug was introduced in PR #4470, commit 678a92cb56d547dcadffa723e29b4855a27d0901
* Replace missed usages of FrozenEventErik Johnston2019-01-252-4/+12
|
* Revert "Require event format version to parse or create events"Erik Johnston2019-01-252-12/+4
|
* Replace missed usages of FrozenEventErik Johnston2019-01-242-4/+12
|
* Fix logging bug in EDU handling over replicationErik Johnston2018-08-171-1/+1
|
* Use federation handler function rather than duplicateErik Johnston2018-08-151-41/+3
| | | | This involves renaming _persist_events to be a public function.
* Move clean_room_for_join to masterErik Johnston2018-08-091-0/+35
|
* Fixup doc commentsErik Johnston2018-08-091-0/+17
|
* Merge branch 'develop' of github.com:matrix-org/synapse into ↵Erik Johnston2018-08-093-16/+62
|\ | | | | | | erikj/split_federation
| * Fixup wording and remove dead codeErik Johnston2018-08-091-2/+1
| |
| * Rename POST param to METHODErik Johnston2018-08-082-13/+22
| |
| * Fixup logging and docstringsErik Johnston2018-08-082-2/+40
| |
* | Add EDU/query handling over replicationErik Johnston2018-08-061-1/+1
| |
* | Add replication APIs for persisting federation eventsErik Johnston2018-08-062-1/+247
|/
* Fix isortErik Johnston2018-08-061-4/+1
|
* Merge branch 'develop' of github.com:matrix-org/synapse into ↵Erik Johnston2018-08-031-4/+3
|\ | | | | | | erikj/refactor_repl_servlet
| * Kill off MatrixCodeMessageExceptionRichard van der Hoff2018-08-012-16/+12
| | | | | | | | | | | | | | | | | | | | | | This code brings the SimpleHttpClient into line with the MatrixFederationHttpClient by having it raise HttpResponseExceptions when a request fails (rather than trying to parse for matrix errors and maybe raising MatrixCodeMessageException). Then, whenever we were checking for MatrixCodeMessageException and turning them into SynapseErrors, we now need to check for HttpResponseExceptions and call to_synapse_error.
* | Use new helper base class for membership requestsErik Johnston2018-07-311-171/+91
| |
* | Use new helper base class for ReplicationSendEventRestServletErik Johnston2018-07-311-79/+36
| |
* | Add helper base class for generating new replication endpointsErik Johnston2018-07-311-0/+208
|/ | | | | This will hopefully reduce the boiler plate required to implement new internal HTTP requests.
* Fix missing attributes on workers.Erik Johnston2018-07-231-2/+5
| | | | | This was missed during the transition from attribute to getter for getting state from context.
* run isortAmber Brown2018-07-093-8/+9
|
* Pass around the reactor explicitly (#3385)Amber Brown2018-06-221-3/+3
|
* Refactor ResponseCache usageRichard van der Hoff2018-04-121-12/+6
| | | | | | | | | | | | | | | Adds a `.wrap` method to ResponseCache which wraps up the boilerplate of a (get, set) pair, and then use it throughout the codebase. This will be largely non-functional, but does include the following functional changes: * federation_server.on_context_state_request: drops use of _server_linearizer which looked redundant and could cause incorrect cache misses by yielding between the get and the set. * RoomListHandler.get_remote_public_room_list(): fixes logcontext leaks * the wrap function includes some logging. I'm hoping this won't be too noisy on production.
* Add metrics for ResponseCacheRichard van der Hoff2018-04-101-1/+1
|
* Fix importsErik Johnston2018-03-142-7/+4
|
* s/join/joined/ in notify_user_membership_changeErik Johnston2018-03-141-3/+3
|
* Implement RoomMemberWorkerHandlerErik Johnston2018-03-132-0/+336
|
* extra_users is actually a list of UserIDsErik Johnston2018-03-131-4/+4
|
* Log in the correct placesErik Johnston2018-03-011-2/+4
|
* Don't do preserve_fn for every requestErik Johnston2018-03-011-1/+2
|
* Add some loggingErik Johnston2018-03-011-0/+2
|
* Make repl send_event idempotent and retry on timeoutsErik Johnston2018-03-011-6/+38
| | | | | | If we treated timeouts as failures on the worker we would attempt to clean up e.g. push actions while the master might still process the event.
* Correctly send ratelimit and extra_users paramsErik Johnston2018-03-011-1/+13
|
* Calculate push actions on workerErik Johnston2018-02-281-1/+1
|
* Don't serialize current state over replicationErik Johnston2018-02-151-2/+2
|
* Don't log errors propogated from send_eventErik Johnston2018-02-151-1/+10
|
* Add replication http endpoint for event sendingErik Johnston2018-02-072-0/+139