Skip to content

Commit

Permalink
Upgrade sled to 0.34.7
Browse files Browse the repository at this point in the history
This fixes a bug where the frontend did not receive file list updates.
  • Loading branch information
tv42 committed Mar 22, 2022
1 parent 6580e06 commit 9dc2ef8
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion server/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ log = { version = "0.4.14", features = ["kv_unstable", "kv_unstable_std"] }
serde_json = "1.0.79"
ron = "0.7.0"
thiserror = "1.0.30"
sled = "0.34.6"
sled = "0.34.7"
sleigh = { path = "../sleigh" }
itertools = "0.10.3"
structopt = "0.3.26"
2 changes: 1 addition & 1 deletion server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ async fn ws_list_events(state: Arc<State>, conn: ws::Conn) -> tide::Result<()> {
// Hence, we buffer the subscriber events while the initial scan is working.
// In this use case, we can coalesce the events by key.
// That might consume a lot of memory, but in this use case we're roughly bounded by the number of files changes noticed in one scan, which we assume we can already hold in memory elsewhere.
let subscriber = state.media.watch_prefix("");
let mut subscriber = state.media.watch_prefix("");

// Do sled tree watching in a separate thread, with a channel between them, to notice slow consumers and kick them out, instead of blocking the database.
let (sender, receiver) = std::sync::mpsc::sync_channel(1000);
Expand Down
2 changes: 1 addition & 1 deletion sleigh/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ edition = "2018"
bincode = "1.3.3"
lazy_static = "1.4.0"
serde = "1.0.136"
sled = "0.34.6"
sled = "0.34.7"
thiserror = "1.0.30"
2 changes: 1 addition & 1 deletion sleigh/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ where
}

pub fn next_timeout(
&self,
&mut self,
timeout: Duration,
) -> Result<Event<V>, SubscriberTimeoutError<Enc::Error>> {
let orig = self.sub.next_timeout(timeout)?;
Expand Down

0 comments on commit 9dc2ef8

Please sign in to comment.