Brendan Abolivier
bb78276bdc
Incorporate review
2019-11-07 15:25:27 +00:00
Brendan Abolivier
b9cba07962
Lint
2019-11-07 14:57:15 +00:00
Brendan Abolivier
70804392ae
Only join on event_labels if we're filtering on labels
2019-11-07 14:55:10 +00:00
Brendan Abolivier
15a1a02e70
Handle lack of filter
2019-11-07 12:04:37 +00:00
Brendan Abolivier
4f519d556e
Changelog
2019-11-07 11:51:54 +00:00
Brendan Abolivier
3f9b61ff95
Fix the SQL SELECT query in _paginate_room_events_txn
...
Doing a SELECT DISTINCT when paginating is quite expensive, because it requires the engine to do sorting on the entire events table. However, we only need to run it if we're filtering on 2+ labels, so this PR is changing the request so that DISTINCT is only used then.
2019-11-07 11:51:11 +00:00
Andrew Morgan
e914cf12f6
Merge pull request #6235 from matrix-org/anoa/room_upgrade_groups
2019-11-07 11:12:22 +00:00
Richard van der Hoff
b03cddaeb9
tweak changelog
2019-11-07 09:46:25 +00:00
V02460
affcc2cc36
Fix LruCache callback deduplication ( #6213 )
2019-11-07 09:43:51 +00:00
Brendan Abolivier
f03c9d3444
Don't apply retention policy based filtering on state events
...
As per MSC1763, 'Retention is only considered for non-state events.', so don't filter out state events based on the room's retention policy.
2019-11-06 18:40:04 +00:00
Andrew Morgan
a6ebef1bfd
Make numeric user_id checker start at @0, and don't ratelimit on checking ( #6338 )
2019-11-06 17:21:20 +00:00
Erik Johnston
5c3363233c
Fix deleting state groups during room purge.
...
And fix the tests to actually test that things got deleted.
2019-11-06 17:02:08 +00:00
Erik Johnston
71f3bd734f
Use correct type annotation
2019-11-06 17:00:18 +00:00
Andrew Morgan
55bc8d531e
raise exception after multiple failures
2019-11-06 16:52:54 +00:00
Andrew Morgan
1fe3cc2c9c
Address review comments
2019-11-06 14:54:24 +00:00
Richard van der Hoff
915903eada
Merge branch 'master' into develop
2019-11-06 13:51:11 +00:00
Richard van der Hoff
08b2868ffe
Merge branch 'release-v1.5.1'
2019-11-06 13:50:55 +00:00
Richard van der Hoff
4257feb20f
build debs for eoan and bullseye
2019-11-06 13:35:56 +00:00
Andrew Morgan
d2f6a67cb4
Add changelog
2019-11-06 12:03:12 +00:00
Andrew Morgan
4059d61e26
Don't forget to ratelimit calls outside of RegistrationHandler
2019-11-06 12:01:54 +00:00
Andrew Morgan
b33c4f7a82
Numeric ID checker now checks @0, don't ratelimit on checking
2019-11-06 11:55:00 +00:00
Erik Johnston
4fc53bf1fb
Newsfile
2019-11-06 11:08:58 +00:00
Erik Johnston
f697b4b4a2
Add failed auth ratelimiting to UIA
2019-11-06 11:08:58 +00:00
Erik Johnston
541f1b92d9
Only do rc_login
ratelimiting on succesful login.
...
We were doing this in a number of places which meant that some login
code paths incremented the counter multiple times.
It was also applying ratelimiting to UIA endpoints, which was probably
not intentional.
In particular, some custom auth modules were calling
`check_user_exists`, which incremented the counters, meaning that people
would fail to login sometimes.
2019-11-06 11:08:58 +00:00
Brendan Abolivier
24a214bd1b
Fix field name
2019-11-06 11:04:19 +00:00
Brendan Abolivier
70d93cafdb
Update insert
2019-11-06 10:59:03 +00:00
Richard van der Hoff
feafd98aca
1.5.1
2019-11-06 10:02:23 +00:00
Richard van der Hoff
807ec3bd99
Fix bug which caused rejected events to be stored with the wrong room state ( #6320 )
...
Fixes a bug where rejected events were persisted with the wrong state group.
Also fixes an occasional internal-server-error when receiving events over
federation which are rejected and (possibly because they are
backwards-extremities) have no prev_group.
Fixes #6289 .
2019-11-06 10:01:39 +00:00
Richard van der Hoff
0e3ab8afdc
Add some checks that we aren't using state from rejected events ( #6330 )
...
* Raise an exception if accessing state for rejected events
Add some sanity checks on accessing state_group etc for
rejected events.
* Skip calculating push actions for rejected events
It didn't actually cause any bugs, because rejected events get filtered out at
various later points, but there's not point in trying to calculate the push
actions for a rejected event.
2019-11-05 22:13:37 +00:00
Erik Johnston
01ba7b38a7
Merge pull request #6336 from matrix-org/erikj/fix_phone_home_stats
...
Fix phone home stats
2019-11-05 18:29:57 +00:00
Erik Johnston
b437eb48b6
Newsfile
2019-11-05 17:45:29 +00:00
Erik Johnston
052513958d
Fix phone home stats
2019-11-05 17:44:09 +00:00
Richard van der Hoff
5570d1c93f
Merge pull request #6334 from matrix-org/rav/url_preview_limit_title_2
...
Fix exception when OpenGraph tag values are ints
2019-11-05 17:28:11 +00:00
Richard van der Hoff
81d49cbb07
Fix exception when OpenGraph tag values are ints
2019-11-05 17:22:58 +00:00
Richard van der Hoff
02f99906f2
Merge pull request #6331 from matrix-org/rav/url_preview_limit_title
...
Strip overlong OpenGraph data from url preview
2019-11-05 17:08:59 +00:00
Richard van der Hoff
55a7da247a
Merge branch 'develop' into rav/url_preview_limit_title
2019-11-05 17:08:07 +00:00
Richard van der Hoff
e78167c94b
Apply suggestions from code review
...
Co-Authored-By: Brendan Abolivier <babolivier@matrix.org>
Co-Authored-By: Erik Johnston <erik@matrix.org>
2019-11-05 16:46:39 +00:00
Erik Johnston
248111bae8
Newsfile
2019-11-05 15:54:23 +00:00
Richard van der Hoff
e9bfe719ba
Strip overlong OpenGraph data from url preview
...
... to stop people causing DoSes with malicious web pages
2019-11-05 15:51:18 +00:00
Erik Johnston
c16e192e2f
Fix caching devices for remote servers in worker.
...
When the `/keys/query` API is hit on client_reader worker Synapse may
decide that it needs to resync some remote deivces. Usually this happens
on master, and then gets cached. However, that fails on workers and so
it falls back to fetching devices from remotes directly, which may in
turn fail if the remote is down.
2019-11-05 15:49:43 +00:00
Brendan Abolivier
f5d8fdf0a7
Update changelog
2019-11-05 14:44:25 +00:00
Richard van der Hoff
4086002827
Improve documentation for EventContext fields ( #6319 )
2019-11-05 13:23:25 +00:00
Erik Johnston
ffe595381d
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/split_purge_history
2019-11-05 10:27:41 +00:00
Andrew Morgan
506a63de67
Merge branch 'develop' of github.com:matrix-org/synapse into anoa/room_upgrade_groups
2019-11-04 18:22:41 +00:00
Andrew Morgan
c2203bea57
Re-add docstring, with caveats detailed
2019-11-04 18:17:11 +00:00
Brendan Abolivier
e252ffadbc
Merge branch 'develop' into babolivier/msc2326_bg_update
2019-11-04 18:09:50 +00:00
Andrew Morgan
0287d033ee
Transfer upgraded rooms on groups
2019-11-04 18:08:50 +00:00
Amber Brown
4e1c7b79fa
Remove the psutil dependency ( #6318 )
...
* remove psutil and replace with resource
2019-11-05 05:05:48 +11:00
Brendan Abolivier
09957ce0e4
Implement per-room message retention policies
2019-11-04 17:09:22 +00:00
Erik Johnston
7134ca7daa
Change to not require a state_groups.room_id index.
...
This does mean that we won't clean up orphaned state groups (i.e. state
groups that were persisted but the associated event wasn't).
2019-11-04 13:36:57 +00:00