Commit graph

1747 commits

Author SHA1 Message Date
Neil Alexander 0caf8cf53e
Some review comments 2022-02-04 09:27:35 +00:00
Neil Alexander 9a2210495b
Minor bug fixes with latest event updater 2022-02-03 13:17:24 +00:00
Neil Alexander 31cc9be470
Merge branch 'neilalexander/rstxn' of github.com:matrix-org/dendrite into neilalexander/rstxn 2022-02-03 11:38:49 +00:00
Neil Alexander e8f26cdedf
Fix rollback 2022-02-03 11:38:34 +00:00
Neil Alexander fe56651fa2
Merge branch 'master' into neilalexander/rstxn 2022-02-02 17:47:20 +00:00
Neil Alexander 4d9f5b2e57
Fix panic from closing the input channel before the workers complete (it'll get GC'd either way) 2022-02-02 17:46:37 +00:00
Neil Alexander 2a5c38fee2
Use background contexts during federated join for clarity (#2134)
* Use background contexts for clarity

* Don't wait for the context to expire before trying to return

* Actually we don't really need a goroutine here
2022-02-02 17:33:36 +00:00
Neil Alexander d1baa305ae
Hopefully fix panics for good in SQLite this time 2022-02-02 16:55:48 +00:00
Neil Alexander 885c70c31c
Tweaks 2022-02-02 16:40:59 +00:00
Neil Alexander 436f07e79d
Don't panic on nil txns 2022-02-02 16:26:56 +00:00
Neil Alexander f49f4e55e0
Fix incorrect error check 2022-02-02 15:52:02 +00:00
Neil Alexander f58ee67a7a
Fix bugs 2022-02-02 15:42:22 +00:00
Neil Alexander 2ca972ef76
Pass through errors properly 2022-02-02 15:24:45 +00:00
Neil Alexander 15038eb2e7
Don't roll back transactions when events rejected 2022-02-02 15:04:33 +00:00
Neil Alexander 9fb2503493
good lord it gets worse 2022-02-02 14:47:39 +00:00
Neil Alexander 111a65fe89
Fill in the gaps 2022-02-02 14:18:45 +00:00
Neil Alexander 250a0ee946
Fill some gaps 2022-02-02 14:12:55 +00:00
Neil Alexander e8f58acf03
Merge branch 'master' into neilalexander/rstxn 2022-02-02 14:02:51 +00:00
Neil Alexander c773b038bb
Use pull consumers (#2140)
* Pull consumers

* Pull consumers

* Only nuke consumers if they are push consumers

* Clean up old consumers

* Better error handling

* Update comments
2022-02-02 13:32:48 +00:00
kegsay 2dee706f9e
PerformInvite: bugfix and rejig control flow (#2137)
* PerformInvite: bugfix and rejig control flow

Local clients would not be notified of invites to rooms
Dendrite had already joined in all cases due to not returning
an `api.OutputNewInviteEvent` for local invites. We now do this.

This was an easy mistake to make due to the control flow of the
function which doesn't handle the happy case at the end of the
function and instead forks the function depending on if the
invite was via federation or not. This has now been changed to
handle the federated invite as if it were an error (in that we
check it, do it and bail out) rather than outstay our welcome.
This ends up with the local invite being the happy case, which
now both sends an `InputRoomEvent` to the roomserver _and_ a
`api.OutputNewInviteEvent` is returned.

* Don't send invite pokes in PerformInvite

* Move event ID into logger
2022-02-02 13:30:48 +00:00
kegsay a09d71d231
Support CA certificates in CI (#2136)
* Support CA setting in generate-keys

* Set DNS names correctly

* Use generate-config -server not sed
2022-02-01 16:36:17 +00:00
Neil Alexander 9ada4578e3
Fix JetStream paths for P2P demo builds 2022-02-01 16:03:30 +00:00
Neil Alexander fdbb2406be
More tweaks 2022-02-01 14:54:28 +00:00
Neil Alexander 418339011c
Other fixes 2022-02-01 14:01:58 +00:00
Neil Alexander b4c136a9c4
Handle cases where the room does not exist 2022-02-01 13:31:45 +00:00
Neil Alexander e0a485c50d
Tweak order 2022-02-01 13:15:20 +00:00
Neil Alexander 8cbf67a2f2
Better transaction management 2022-02-01 13:14:21 +00:00
Neil Alexander f2c0bb165e
Add transaction to all database tables in roomserver, rename latest events updater to room updater, use room updater for all RS input 2022-02-01 12:52:37 +00:00
Neil Alexander 893aa3b141
More logging tweaks 2022-01-31 16:01:54 +00:00
Neil Alexander 07d0e72a8b
Improve roomserver logging 2022-01-31 15:33:00 +00:00
Neil Alexander d21f3eace0
Roomserver fixes (#2133)
* Improve server selection somewhat

* Remove things from the map when we're done

* Be less panicky about auth event signatures in case they are not fatal after all

* Accept HasState in all cases

* Send join asynchronously

* Revert "Send join asynchronously"

This reverts commit 5b685bfcd0.

* Joins and leaves use background context
2022-01-31 14:36:59 +00:00
Neil Alexander 567fd04428
Update to matrix-org/gomatrixserverlib#286 2022-01-31 14:29:13 +00:00
Hoernschen 1d5fd99cad
Allow uppercase username on login (#2126)
* ADD jetstream folder to gitignore

* CHANGE login to check on uppercase if lowercase not exists

Co-authored-by: kegsay <kegan@matrix.org>
2022-01-31 13:44:52 +00:00
Neil Alexander f9547a53d2
Tweak roomserver logging for rejected events 2022-01-31 12:01:53 +00:00
Neil Alexander dac762d025
Revert Prometheus client upgrades altogether 2022-01-31 11:47:07 +00:00
Neil Alexander 2995f73ae0
Update prometheus client 2022-01-31 11:16:21 +00:00
Neil Alexander 5367e7ed2c
Update to matrix-org/gomatrixserverlib@801c51af9f 2022-01-31 10:51:01 +00:00
Neil Alexander ba1a9b98b7
Tweak some logging (#2130)
* Modify some log levels

* Update gomatrixserverlib to matrix-org/gomatrixserverlib@336334f

* Update gomatrixserverlib to matrix-org/gomatrixserverlib@cde7ac8

* Demote warning about key change producer

* Add more useful roomserver logging

* Further tweaking
2022-01-31 10:48:28 +00:00
Neil Alexander eb8e770e99
Revert consumer change 2022-01-31 10:42:41 +00:00
Neil Alexander a271fde8f5
Only limit context for fetching missing auth/prev events (#2131) 2022-01-31 10:39:33 +00:00
Neil Alexander 4281976df9
Update Sarama to fix 32-bit builds (#2120) 2022-01-28 17:31:54 +00:00
Neil Alexander 2c3dd48bb2
Require Go 1.16 (#2122) 2022-01-28 16:24:01 +00:00
Neil Alexander bde7c1fd8c
Version 0.6 (#2117)
* Bump version, release notes

* Update changelog

* Update changelog
2022-01-28 14:13:36 +00:00
Neil Alexander 8e4002831f
Call hooks for outliers (#2119)
* Move hook call when processing room events

* Fix build

* Call hooks for outliers too
2022-01-28 13:11:56 +00:00
Neil Alexander e9fbad6f20
Move hook call when processing room events (#2118)
* Move hook call when processing room events

* Fix build
2022-01-28 12:33:31 +00:00
kegsay 2ea5fd4162
Add debug logging for incoming CSAPI calls on authentication failure (#2116)
* Add debug logging for incoming CSAPI calls on authentication failure

Will help to debug Complement failures, and just generally useful.

* Update httpapi.go

Co-authored-by: Neil Alexander <neilalexander@users.noreply.github.com>
2022-01-28 11:14:20 +00:00
S7evinK f034098877
"Enable" remote room search (#2099)
* "Enable" remote room search

Signed-off-by: Till Faelligen <tfaelligen@gmail.com>

* Update go.mod

* Fix formatting
2022-01-28 11:07:47 +00:00
Neil Alexander 48789ebec5
Don't flood Sentry with context cancelled/deadline exceeded errors (#2115) 2022-01-28 10:27:28 +00:00
Neil Alexander 2f72688e9a
Upgrade dependencies (#2074)
* Upgrade dependencies

* Revert gjson/sjson due to panics

* Revert sarama as it requires Go 1.16

* Revert quic-go as it requires Go 1.16

* Revert sarama again
2022-01-28 10:27:09 +00:00
Neil Alexander b626143694
Update gomatrixserverlib 2022-01-28 10:01:20 +00:00