Commit graph

1560 commits

Author SHA1 Message Date
strawberry
ae392daae2 add legacy v1 routes for the remaining media endpoints
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-15 23:21:51 -04:00
strawberry
805ed6a004 check if rocksdb_max_log_files is 0
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-15 22:39:28 -04:00
strawberry
9e28dae0ce treat non-appservice registrations as None auth
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 19:49:12 -04:00
strawberry
52c7358bf3 add unimplemented default impl to fix sqlite building
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 19:41:33 -04:00
strawberry
cc0f522371 remove some conditional compilation
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 19:41:10 -04:00
strawberry
d1188a08f1 Revert "switch to hickory-dns / hickory_resolver"
This reverts commit 2ea524bfab.
2024-03-14 19:05:15 -04:00
strawberry
5811c6364c dont allow GetRemotePdu server to be ourselves
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 01:44:35 -04:00
strawberry
0ba08b64d2 drop sync requests to debug
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 01:44:19 -04:00
strawberry
022b1febe2 remove unnecessary variable qualifications
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 01:13:00 -04:00
strawberry
307f280819 add room alias server names for backfill, self check server name
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 01:05:43 -04:00
strawberry
95a518e599 add room ID server_name as backfill server, make servers a vector
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 00:41:33 -04:00
strawberry
de46788910 (hopefully?) implement AuthScheme::AppserviceToken
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 00:16:25 -04:00
strawberry
cd6217a65e silence unused_qualification clippys warning due to async traits
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-14 00:15:21 -04:00
strawberry
7244184b35 check if federation is enabled in GetRemotePdu
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 23:51:24 -04:00
strawberry
078d4c9bab handle GetRemotePdu response as backfilled PDU
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 23:45:37 -04:00
strawberry
b5dce0cc5f some more rocksdb conditional compilation
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 22:41:12 -04:00
strawberry
d05a27e4f4 add rocksdb_bottommost_compression_level config option
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 22:38:30 -04:00
strawberry
f5bd1f7bfa add RocksDB rocksdb_compression_level and rocksdb_bottommost_compression
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 22:22:07 -04:00
strawberry
572fc29d64 split GetPdu and GetRemotePdu, handle response as incoming PDU
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 21:39:43 -04:00
Jason Volk
fcf3ef8931 use WriteBatchWithTransaction for batched insertions.
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 16:38:24 -04:00
strawberry
72fde3fed5 apply Read/Write/FlushOptions where available for future usage
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 12:42:16 -04:00
strawberry
0abf393ce8 simplify/tune rocksdb options, config option for compression algo
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 12:31:13 -04:00
Timo Kösters
2a4450e930 dont leak users in room directory if sender is not allowed to see them
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 11:37:28 -04:00
strawberry
fd0ab1ef75 log sync sender_user
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 11:36:42 -04:00
strawberry
de2f920696 make config PathBuf instead of String
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 02:12:14 -04:00
strawberry
d0bb464d88 add multi_get (multi_get_cf) for rocksdb
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 02:08:43 -04:00
Charles Hall
3bdb95c3ef refactor clap into a separate file
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-13 02:08:29 -04:00
strawberry
2ea524bfab switch to hickory-dns / hickory_resolver
trust-dns rebranded to hickry-dns

Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-11 20:20:35 -04:00
strawberry
6827a78115 fix User-Agent
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-11 20:20:35 -04:00
strawberry
27ac0a92af disable update check by default
save the few bytes of bandwidth for something else

also now that we send our User-Agent, it is
technically sending conduwuit versions now

Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-11 20:20:35 -04:00
strawberry
9354c9e8b5 update image(-rs)
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 20:39:42 -04:00
strawberry
c2f8d119cd clearly document where this code came from
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 20:39:15 -04:00
strawberry
57444588d0 admin cmd to fetch PDU from remote server
does not append to timeline/database yet

Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 20:30:35 -04:00
strawberry
e888a0a745 drop dead server log spam to debug
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
39d9cc9d33 fix sqlite lints
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
82247f7ab9 fix test
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
a49e79caff resolve windows-only lints
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
d52f03414e add commandline arg to specify a conduwuit config file
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
aec7097cd3 tokio signals are actually used for CTRL+C
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
26982fbe05 make these variables unix only too
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
fee6cad778 s/rocksdb/rust_rocksdb, fix copy paste errors
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
d84378db18 build unix socket support on unix platforms only
yes windows technically supports unix sockets,
but its not as good or the same as actual
nix platform unix sockets

Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
39aef8d1b9 dont build sha2, opentelemetry, or zstd code if unused
reduces unnecessary crates being compiled. splits them
into features.

i have yet to see anyone use conduit's opentelemetry
stuff, and realistically those people who do
performance benchmarking and measurements will be
building stuff anyways so they can just enable this
feature.

Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
958b738e5a drop querying _matrix SRV record to debug
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-10 13:03:28 -04:00
strawberry
5c94caa3bb temp: dont fetch remote profiles for remote membership updates
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 18:09:41 -05:00
strawberry
1a40171bc1 log warning for failed preview gen, better error message
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 18:09:41 -05:00
strawberry
1911f5a8fa fix cargo doc lint
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
strawberry
c58f93105a implement legacy "v1" media request routes
if https://github.com/ruma/ruma/issues/1240 is to
be trusted, there are apparently still servers
and clients that may call these endpoints.

i'm unable to read the history of that matrix.to
link so i don't know the full context, but this
is trivial to implement so..

Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
strawberry
496a9c7af8 resolve some pedantic lints, reduce some allocations
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00
Matthias Ahouansou
5ab76a1332 update ruma appservice Registration type MR
from https://gitlab.com/famedly/conduit/-/merge_requests/583

and fixed panic from blocking async call in timeline/mod.rs

Co-authored-by: strawberry <strawberry@puppygock.gay>
Signed-off-by: strawberry <strawberry@puppygock.gay>
2024-03-08 12:51:21 -05:00