Compare commits
4 Commits
3b332c1123
...
409e84951b
Author | SHA1 | Date | |
---|---|---|---|
409e84951b | |||
f7527e6bc5 | |||
0106b2bfea | |||
b6020b99c6 |
20
Cargo.lock
generated
20
Cargo.lock
generated
@ -21,9 +21,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "actix-http"
|
name = "actix-http"
|
||||||
version = "3.10.0"
|
version = "3.11.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "0fa882656b67966045e4152c634051e70346939fced7117d5f0b52146a7c74c9"
|
checksum = "44dfe5c9e0004c623edc65391dfd51daa201e7e30ebd9c9bedf873048ec32bc2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"actix-codec",
|
"actix-codec",
|
||||||
"actix-rt",
|
"actix-rt",
|
||||||
@ -106,9 +106,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "actix-server"
|
name = "actix-server"
|
||||||
version = "2.5.1"
|
version = "2.6.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "6398974fd4284f4768af07965701efbbb5fdc0616bff20cade1bb14b77675e24"
|
checksum = "a65064ea4a457eaf07f2fba30b4c695bf43b721790e9530d26cb6f9019ff7502"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"actix-rt",
|
"actix-rt",
|
||||||
"actix-service",
|
"actix-service",
|
||||||
@ -161,9 +161,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "actix-web"
|
name = "actix-web"
|
||||||
version = "4.10.2"
|
version = "4.11.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "f2e3b15b3dc6c6ed996e4032389e9849d4ab002b1e92fbfe85b5f307d1479b4d"
|
checksum = "a597b77b5c6d6a1e1097fddde329a83665e25c5437c696a3a9a4aa514a614dea"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"actix-codec",
|
"actix-codec",
|
||||||
"actix-http",
|
"actix-http",
|
||||||
@ -621,9 +621,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "brotli"
|
name = "brotli"
|
||||||
version = "7.0.0"
|
version = "8.0.1"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "cc97b8f16f944bba54f0433f07e30be199b6dc2bd25937444bbad560bcea29bd"
|
checksum = "9991eea70ea4f293524138648e41ee89b0b2b12ddef3b255effa43c8056e0e0d"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"alloc-no-stdlib",
|
"alloc-no-stdlib",
|
||||||
"alloc-stdlib",
|
"alloc-stdlib",
|
||||||
@ -632,9 +632,9 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "brotli-decompressor"
|
name = "brotli-decompressor"
|
||||||
version = "4.0.2"
|
version = "5.0.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "74fa05ad7d803d413eb8380983b092cbbaf9a85f151b871360e7b00cd7060b37"
|
checksum = "874bb8112abecc98cbd6d81ea4fa7e94fb9449648c93cc89aa40c81c24d7de03"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"alloc-no-stdlib",
|
"alloc-no-stdlib",
|
||||||
"alloc-stdlib",
|
"alloc-stdlib",
|
||||||
|
@ -12,7 +12,7 @@ anyhow = "1.0.98"
|
|||||||
serde = { version = "1.0.219", features = ["derive"] }
|
serde = { version = "1.0.219", features = ["derive"] }
|
||||||
serde_json = "1.0.140"
|
serde_json = "1.0.140"
|
||||||
rust-s3 = { version = "0.36.0-beta.2", features = ["tokio"] }
|
rust-s3 = { version = "0.36.0-beta.2", features = ["tokio"] }
|
||||||
actix-web = "4.10.2"
|
actix-web = "4.11.0"
|
||||||
actix-session = { version = "0.10.1", features = ["redis-session"] }
|
actix-session = { version = "0.10.1", features = ["redis-session"] }
|
||||||
light-openid = "1.0.4"
|
light-openid = "1.0.4"
|
||||||
thiserror = "2.0.12"
|
thiserror = "2.0.12"
|
||||||
|
@ -42,5 +42,5 @@ pub enum BroadcastMessage {
|
|||||||
/// Stop a client with a given client ID
|
/// Stop a client with a given client ID
|
||||||
StopSyncClient(SyncClientID),
|
StopSyncClient(SyncClientID),
|
||||||
/// Propagate a new sync event
|
/// Propagate a new sync event
|
||||||
SyncEvent(UserID, SyncEvent),
|
SyncEvent(UserID, Box<SyncEvent>),
|
||||||
}
|
}
|
||||||
|
@ -94,7 +94,7 @@ pub async fn ws_handler(
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Send the message to the websocket
|
// Send the message to the websocket
|
||||||
if let Ok(msg) = serde_json::to_string(&WsMessage::Sync(event)) {
|
if let Ok(msg) = serde_json::to_string(&WsMessage::Sync(*event)) {
|
||||||
if let Err(e) = session.text(msg).await {
|
if let Err(e) = session.text(msg).await {
|
||||||
log::error!("Failed to send SyncEvent: {}", e);
|
log::error!("Failed to send SyncEvent: {}", e);
|
||||||
}
|
}
|
||||||
|
@ -122,12 +122,12 @@ async fn sync_task(
|
|||||||
match msg_stream {
|
match msg_stream {
|
||||||
Ok(Some(msg)) => {
|
Ok(Some(msg)) => {
|
||||||
log::debug!("Received new message from Matrix: {msg:#?}");
|
log::debug!("Received new message from Matrix: {msg:#?}");
|
||||||
if let Err(e) = tx.send(BroadcastMessage::SyncEvent(user_id.clone(), SyncEvent {
|
if let Err(e) = tx.send(BroadcastMessage::SyncEvent(user_id.clone(), Box::new(SyncEvent {
|
||||||
rooms: msg.rooms,presence: msg.presence,
|
rooms: msg.rooms,presence: msg.presence,
|
||||||
account_data: msg.account_data,
|
account_data: msg.account_data,
|
||||||
to_device: msg.to_device,
|
to_device: msg.to_device,
|
||||||
device_lists: msg.device_lists,
|
device_lists: msg.device_lists,
|
||||||
})) {
|
}))) {
|
||||||
log::error!("Failed to propagate event! {e}");
|
log::error!("Failed to propagate event! {e}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user