Skip to content

Commit 6fbf197

Browse files
committedFeb 14, 2025
chore: replace async-channel with already exist flume dep
Signed-off-by: tison <wander4096@gmail.com>
1 parent 26a7e88 commit 6fbf197

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed
 

‎foyer-storage/Cargo.toml

-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ allocator-api2 = "0.2"
1818
anyhow = "1.0"
1919
# TODO(MrCroxx): use `array_chunks` after `#![feature(array_chunks)]` is stable.
2020
array-util = "1"
21-
async-channel = "2"
2221
auto_enums = { version = "0.8", features = ["futures03"] }
2322
bincode = "1"
2423
bytes = "1"

‎foyer-storage/src/region.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ use std::{
2424
task::{Context, Poll},
2525
};
2626

27-
use async_channel::{Receiver, Sender};
27+
use flume::{Receiver, Sender};
2828
use foyer_common::{countdown::Countdown, metrics::Metrics};
2929
use futures_core::future::BoxFuture;
3030
use futures_util::{future::Shared, FutureExt};
@@ -154,7 +154,7 @@ impl RegionManager {
154154
stats: Arc::new(RegionStats::default()),
155155
})
156156
.collect_vec();
157-
let (clean_region_tx, clean_region_rx) = async_channel::unbounded();
157+
let (clean_region_tx, clean_region_rx) = flume::unbounded();
158158

159159
metrics.storage_region_total.absolute(device.regions() as _);
160160
metrics.storage_region_size_bytes.absolute(device.region_size() as _);

0 commit comments

Comments
 (0)