Matthew Hodgson
ab9f844aaf
Add federation_domain_whitelist option ( #2820 )
...
Add federation_domain_whitelist
gives a way to restrict which domains your HS is allowed to federate with.
useful mainly for gracefully preventing a private but internet-connected HS from trying to federate to the wider public Matrix network
2018-01-22 19:11:18 +01:00
Richard van der Hoff
3079f80d4a
Factor out `event_from_pdu_json`
...
turns out we have two copies of this, and neither needs to be an instance
method
2017-12-30 18:40:19 +00:00
Richard van der Hoff
a7b726ad18
federation_client: clean up imports
2017-12-30 18:40:19 +00:00
Richard van der Hoff
7e6fa29cb5
Remove preserve_context_over_{fn, deferred}
...
Both of these functions ae known to leak logcontexts. Replace the remaining
calls to them and kill them off.
2017-11-14 11:22:42 +00:00
Richard van der Hoff
6de74ea6d7
Fix logcontexts in _check_sigs_and_hashes
2017-09-20 01:32:42 +01:00
Richard van der Hoff
4903ccf159
Fix some lies, and other clarifications, in docstrings
...
The documentation on get_json has been wrong ever since the very first commit
to synapse...
2017-04-21 01:31:09 +01:00
Richard van der Hoff
5a16cb4bf0
Ignore backoff history for invites, aliases, and roomdirs
...
Add a param to the federation client which lets us ignore historical backoff
data for federation queries, and set it for a handful of operations.
2017-03-23 12:23:22 +00:00
Richard van der Hoff
4bd597d9fc
push federation retry limiter down to matrixfederationclient
...
rather than having to instrument everywhere we make a federation call,
make the MatrixFederationHttpClient manage the retry limiter.
2017-03-23 09:28:46 +00:00
Richard van der Hoff
45d173a59a
Fix docstring
2017-03-09 15:50:29 +00:00
Erik Johnston
c974116f19
Implement device key caching over federation
2017-01-26 16:07:24 +00:00
Erik Johnston
e6153e1bd1
Fix couple of federation state bugs
2017-01-17 13:22:34 +00:00
Matthew Hodgson
555d702e34
limit total timeout for get_missing_events to 10s
2016-12-31 15:21:37 +00:00
Mark Haines
cc50b1ae53
Remove fallback from get_missing_events.
...
get_missing_events used to fallback to fetching the missing events
individually requesting from every server in the room, one by one.e
This could be unacceptably slow, possibly causing #1732
2016-12-30 18:13:15 +00:00
Erik Johnston
f32fb65552
Add new API appservice specific public room list
2016-12-06 16:12:27 +00:00
Erik Johnston
59ef517e6b
Use new federation_sender DI
2016-11-16 14:47:52 +00:00
Erik Johnston
847d5db1d1
Add transaction queue and transport layer to DI
2016-11-16 14:47:52 +00:00
Erik Johnston
daec6fc355
Move logic into transaction_queue
2016-11-16 14:47:52 +00:00
Erik Johnston
0e830d3770
Rename transaction queue functions to send_*
2016-11-16 14:47:52 +00:00
Erik Johnston
22578545a0
Time out typing over federation
2016-09-23 14:00:52 +01:00
Erik Johnston
23b6701a28
Support filtering remote room lists
2016-09-16 10:24:15 +01:00
Erik Johnston
5810cffd33
Pass since/from parameters over federation
2016-09-15 10:36:19 +01:00
Mark Haines
76b09c29b0
Merge pull request #1110 from matrix-org/markjh/e2e_timeout
...
Add a timeout parameter for end2end key queries.
2016-09-13 10:50:45 +01:00
Mark Haines
949c2c5435
Add a timeout parameter for end2end key queries.
...
Add a timeout parameter for controlling how long synapse will wait
for responses from remote servers. For servers that fail include how
they failed to make it easier to debug.
Fetch keys from different servers in parallel rather than in series.
Set the default timeout to 10s.
2016-09-12 18:17:09 +01:00
Erik Johnston
706b5d76ed
Fix backfill when cannot find an event.
...
`get_pdu` can succeed but return None.
2016-09-12 14:59:51 +01:00
Erik Johnston
52b2318777
Clobber EDUs in send queue
2016-09-09 15:59:08 +01:00
Mark Haines
43954d000e
Add a new method to enqueue the device messages rather than sending a dummy EDU
2016-09-07 16:10:51 +01:00
Erik Johnston
f4778d4cd9
Merge branch 'erikj/pdu_check' of github.com:matrix-org/synapse into develop
2016-09-01 14:40:36 +01:00
Erik Johnston
516a272aca
Ensure we only return a validated pdu in get_pdu
2016-09-01 10:55:02 +01:00
Erik Johnston
bed10f9880
Use state handler instead of get_users_in_room/get_joined_hosts
2016-08-26 14:54:30 +01:00
Erik Johnston
9219139351
Preserve some logcontexts
2016-08-24 11:58:40 +01:00
Erik Johnston
487bc49bf8
Don't stop on 4xx series errors
2016-08-10 13:39:12 +01:00
Erik Johnston
ea8c4094db
Also pull out rejected events
2016-08-10 13:26:13 +01:00
Erik Johnston
f91df1f761
Store if we fail to fetch an event from a destination
2016-08-10 11:31:46 +01:00
Erik Johnston
5f360182c6
Fix a couple of python bugs
2016-08-05 18:08:32 +01:00
Erik Johnston
46453bfc2f
Retry joining via other servers if first one failed
2016-08-05 18:02:03 +01:00
Erik Johnston
2d4de61fb7
Fix typo
2016-08-05 10:48:56 +01:00
Erik Johnston
fccadb7719
Check if we already have the events returned by /state/
2016-08-05 10:43:47 +01:00
Erik Johnston
1515d1b581
Fallback to /state/ on both 400 and 404
2016-08-05 10:24:23 +01:00
Benjamin Saunders
a2b7102eea
Tweak integrity error recovery to work as intended
2016-08-04 20:38:08 -07:00
Erik Johnston
257c41cc2e
Fix typos.
2016-08-04 14:05:45 +01:00
Erik Johnston
e3ee63578f
Tidy up get_events
2016-08-04 14:01:18 +01:00
Erik Johnston
edb33eb163
Rename fields to _ids
2016-08-03 17:19:15 +01:00
Erik Johnston
bcc9cda8ca
Fix copy + paste fails
2016-08-03 17:17:26 +01:00
Erik Johnston
4c56bedee3
Actually call get_room_state
2016-08-03 15:04:29 +01:00
Erik Johnston
520ee9bd2c
Fix syntax error
2016-08-03 15:03:15 +01:00
Erik Johnston
a60a2eaa02
Comment
2016-08-03 14:52:43 +01:00
Erik Johnston
e3a720217a
Add /state_ids federation API
...
The new API only returns the event_ids for the state, as most
requesters will already have the vast majority of the events already.
2016-08-03 14:47:37 +01:00
Erik Johnston
d41a1a91d3
Linearize fetching of gaps on incoming events
...
This potentially stops the server from doing multiple requests for the
same data.
2016-06-15 15:16:14 +01:00
David Baker
963e3ed282
Apparently I am not permitted to have two blank lines here
2016-05-31 17:22:53 +01:00
David Baker
d240796ded
Basic, un-cached support for secondary_directory_servers
2016-05-31 17:20:07 +01:00