Commit Graph

63 Commits

Author SHA1 Message Date
Timo Kösters
5e924227b6 feat: add threadpool for iterator threads, bug fixes, tracing_flame support 2021-07-29 08:49:28 +02:00
Timo Kösters
e0072eff63 Merge branch 'v5' into 'master'
feat: support room version 5

See merge request famedly/conduit!138
2021-07-21 11:05:59 +00:00
Timo Kösters
918df9ca6d feat: support room version 5 2021-07-21 11:59:56 +02:00
phesch
666e1d30a3 Implement From<AnyInitialStateEvent> on PduBuilder
The conversion between the two is now direct and thus shouldn't lose the state_keys.
2021-07-21 10:55:23 +02:00
phesch
ddcf1a715b Fix redacted_because field being sent as a string 2021-05-26 17:38:30 +02:00
Timo Kösters
09157b2096 improvement: federation get_keys and optimize signingkey storage
- get encryption keys over federation
- optimize signing key storage
- rate limit parsing of bad events
- rate limit signature fetching
- dependency bumps
2021-05-21 13:25:24 +02:00
Jonas Platte
af6fea3d4e Refactor some canonical JSON code 2021-05-08 02:13:01 +02:00
Jonas Platte
a0457000ff Upgrade Ruma 2021-05-08 01:54:28 +02:00
Jonas Platte
2e1d7d12ca Refactor usage of CanonicalJsonValue 2021-04-26 19:03:51 +02:00
Timo Kösters
5951294638 feat: join cursed rooms
this removes several restrictions and tries to continue verifying a pdu
event if some auth events fail (it drops/ignores bad pdus)
2021-04-14 09:39:06 +02:00
Timo Kösters
46d8f36a2c fix: media thumbnail calculation and appservice detection 2021-03-23 21:18:16 +01:00
Devin Ragotzy
d0df8b495c Merge remote-tracking branch 'upstream/master' into correct-sendtxn 2021-03-04 08:39:16 -05:00
Timo Kösters
105f893cf3 chore: bump other dependencies to make it work 2021-03-04 12:29:08 +01:00
Timo Kösters
4155a47db1 feat: opentelemetry/jaeger support 2021-03-02 15:08:54 +01:00
Devin Ragotzy
7309b2fba9 WIP gather and update forward extremities 2021-02-09 15:25:30 -05:00
Devin Ragotzy
52392628e9 Convert uses of Box<ServerName> to a ref 2021-02-09 15:22:22 -05:00
Devin Ragotzy
d0b8d0f5fd Fix signature/hash checks, fetch recursive auth events 2021-02-09 15:22:02 -05:00
Devin Ragotzy
cdeb1236a2 Fix clippy warnings remove unused imports 2021-02-09 15:21:14 -05:00
Devin Ragotzy
63af3d3da0 Step 5 in /send just fetches state from incoming server 2021-02-09 15:20:07 -05:00
Devin Ragotzy
4b9976aa74 Update state-res, use the new Event trait
This also bumps ruma to latest and removes js_int infavor of the ruma
re-export
2021-02-09 15:19:47 -05:00
Devin Ragotzy
4a92a29b56 State resolution outline for /send 2021-02-09 15:18:47 -05:00
Devin Ragotzy
164b1633d8 Update ruma to latest, renamed server keys and removed PduStub 2020-12-05 17:44:54 +01:00
Devin Ragotzy
b869aab5d0 Cleanup removing debug printing and logging, append non state events 2020-12-05 17:37:13 +01:00
Devin Ragotzy
c173ce43a5 convert_to_outgoing_federation_event takes CanonicalJsonObj 2020-12-05 17:37:12 +01:00
Devin Ragotzy
86bb93f8cf Remove outdated TODOs, use StateEvent::from_id_value consistently 2020-12-05 17:37:10 +01:00
Devin Ragotzy
234b226468 Fix review issues, Remove EventHash's in prev/auth_events in StateEvent
The latest state-res crate uses ruma's PduRoomV3 PDU's which don't have
tuples of (EventId, EventHashs) like previous versions did (this was
left from rebasing onto master). The Media DB
now takes an optional content_type like the updated ruma structs.
2020-12-05 17:37:10 +01:00
Timo Kösters
304c53c4f5 style: make clippy happier 2020-10-07 12:29:19 +02:00
Timo Kösters
0d6159c2da improvement: get_missing_events route and cleanup 2020-10-01 20:49:15 +02:00
Timo Kösters
ea3aaa6b5c improvement: more efficient /sync with gaps 2020-09-18 10:29:43 +02:00
Timo Kösters
1bf614b0f5 fix: remove transaction_id from pdus over federation 2020-09-15 17:02:20 +02:00
Timo Kösters
b7ab57897b fix: sending slowness 2020-09-15 16:14:59 +02:00
Timo Kösters
f7816b11de feat: send messages over federation 2020-09-15 08:17:06 +02:00
Timo Kösters
e6b1f54857 Merge remote-tracking branch 'origin/master' into federation 2020-09-12 22:23:54 +02:00
Timo Kösters
12a8c9badd fix: join rooms over federation 2020-09-12 21:30:07 +02:00
Timo Kösters
1e8fbd8d50 Update ruma version 2020-09-08 17:32:03 +02:00
Timo
4954df3cc3 feat: handle txn ids 2020-08-25 21:33:44 +02:00
Timo
972babbc79 fix: set limited to true when skipping messages in /sync 2020-08-23 16:43:21 -04:00
Devin Ragotzy
846a0098c1 Split append_pdu -> append_pdu and build_and_append
Move all state event appending to append_state_pdu.
2020-08-23 16:43:21 -04:00
Devin Ragotzy
c4f5a0a631 Keep track of State at event for state resolution
feat: first steps towards joining rooms over federation
Add state-res as a dependency of conduit
Add reverse_topological_power_sort before append_pdu
Implement statehashstatid_pduid tree for keeping track of state
Clean up implementation of state_hash as key for tracking state
2020-08-23 16:43:21 -04:00
Timo
38663228f5 fix: put reason of redaction in the redacted event 2020-08-23 16:47:27 +02:00
Timo
940f533d61 refactor: avoid some allocations when redacting 2020-08-23 16:14:06 +02:00
Devin Ragotzy
d948f896c0 Turn append_pdu args into struct PduBuilder 2020-07-29 21:47:09 +02:00
timokoesters
21eb8d4fe3 fix: problems with pdu serialization 2020-07-29 12:59:40 +02:00
Jonas Platte
09561ccea3 Upgrade ruma 2020-07-26 16:52:43 +02:00
Devin R
33bc666859 Use sync ephemeral events in sync Resposne (remove room_id)
Bump ruma to latest master which also fixes some server name as String
to now being of type Box<ServerName>.
2020-07-21 14:04:39 -04:00
Devin R
9a993fa7c1 Convert Pdu to a validated ruma type when calling to_*_event 2020-07-18 08:22:30 -04:00
Devin R
d02685a4fd Update to latest ruma/ruma commit
This will most likely be the API that is released to crates.io so it
should be fairly stable...
2020-07-17 16:04:05 -04:00
Devin R
63e23154f3 Rebase with key backups and cross signing
Moved back to a fork of ruma with timo's key-backup and cross-signing
branch. Ephemeral events in sync responses are EphemeralRoomEventStub
(they also have no room_id like all of sync responses events)
2020-07-17 16:04:05 -04:00
Devin R
24b6702047 Add to_*_event_stub methods to pdu, filter for correct event kind
When creating some responses (sync) an AnyRoomEventStub is needed for this
PduEvent will deserialize the JSON as a Stub event and a non stub event
when needed. Ephemeral and account events are checked to be the correct
type and filtered out if not. This requires an extra `deserialize` call
which could/should be removed.

TODO: Possibly get rid of EventJson in some places.
2020-07-17 16:03:33 -04:00
Devin R
7c38e53839 Move to depend on ruma monorepo and ruma-events0.22 2020-07-17 16:03:02 -04:00