Skip to content

Commit

Permalink
resume lookup
Browse files Browse the repository at this point in the history
Signed-off-by: xixi <[email protected]>
  • Loading branch information
Hexilee committed Aug 18, 2022
1 parent 9004ba0 commit 130e02f
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions src/fs/tikv_fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -289,15 +289,14 @@ impl AsyncFileSystem for TiFs {
#[tracing::instrument]
async fn lookup(&self, parent: u64, name: ByteString) -> Result<Entry> {
Self::check_file_name(&name)?;
// self.spin_no_delay(move |_, txn| {
// let name = name.clone();
// Box::pin(async move {
// let ino = txn.lookup(parent, name).await?;
// Ok(Entry::new(txn.read_inode(ino).await?.into(), 0))
// })
// })
// .await
Err(super::error::FsError::Unimplemented)
self.spin_no_delay(move |_, txn| {
let name = name.clone();
Box::pin(async move {
let ino = txn.lookup(parent, name).await?;
Ok(Entry::new(txn.read_inode(ino).await?.into(), 0))
})
})
.await
}

#[tracing::instrument]
Expand Down

0 comments on commit 130e02f

Please sign in to comment.