From 2a8991b04a956afbcf52a8a103273a44ecd5a578 Mon Sep 17 00:00:00 2001 From: kkould <2435992353@qq.com> Date: Mon, 30 Sep 2024 07:57:50 +0000 Subject: [PATCH] chore: update tokio_uring --- fusio/src/lib.rs | 4 +--- fusio/src/local/tokio_uring/mod.rs | 4 +--- fusio/src/options.rs | 10 ++++++++-- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/fusio/src/lib.rs b/fusio/src/lib.rs index 1e346d3..ab95665 100644 --- a/fusio/src/lib.rs +++ b/fusio/src/lib.rs @@ -179,9 +179,7 @@ impl Write for &mut W { #[cfg(test)] mod tests { - use std::future::Future; - - use super::{MaybeSend, Read, Write}; + use super::{Read, Write}; use crate::{buf::IoBufMut, Error, IoBuf, Seek}; #[allow(unused)] diff --git a/fusio/src/local/tokio_uring/mod.rs b/fusio/src/local/tokio_uring/mod.rs index 946a578..77d3333 100644 --- a/fusio/src/local/tokio_uring/mod.rs +++ b/fusio/src/local/tokio_uring/mod.rs @@ -1,11 +1,9 @@ #[cfg(feature = "fs")] pub mod fs; -use std::future::Future; - use tokio_uring::fs::File; -use crate::{Error, IoBuf, IoBufMut, MaybeSend, Read, Seek, Write}; +use crate::{Error, IoBuf, IoBufMut, Read, Seek, Write}; #[repr(transparent)] struct TokioUringBuf { diff --git a/fusio/src/options.rs b/fusio/src/options.rs index d2ba23c..8e068fa 100644 --- a/fusio/src/options.rs +++ b/fusio/src/options.rs @@ -5,7 +5,10 @@ use crate::{DynFs, Error}; #[derive(Clone)] #[non_exhaustive] pub enum FsOptions { - #[cfg(all(feature = "fs", any(feature = "tokio", feature = "monoio")))] + #[cfg(all( + feature = "fs", + any(feature = "tokio", feature = "monoio", feature = "tokio-uring") + ))] Local, #[cfg(feature = "aws")] S3 { @@ -20,7 +23,10 @@ pub enum FsOptions { impl FsOptions { pub fn parse(self) -> Result, Error> { match self { - #[cfg(all(feature = "fs", any(feature = "tokio", feature = "monoio")))] + #[cfg(all( + feature = "fs", + any(feature = "tokio", feature = "monoio", feature = "tokio-uring") + ))] FsOptions::Local => Ok(Arc::new(crate::local::LocalFs {})), #[cfg(all(feature = "aws", feature = "object_store"))] FsOptions::S3 {