Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: ofs write behavior #4617

Merged
merged 17 commits into from
May 23, 2024
Merged

fix: ofs write behavior #4617

merged 17 commits into from
May 23, 2024

Conversation

ho-229
Copy link
Contributor

@ho-229 ho-229 commented May 15, 2024

  • Remove unnecessary lseek implementation.
  • Only continuously truncate writes and continuously append writes are allowed.
  • Fix file will be truncate on every write.
  • Fix panic on debug build caused by incorrect use of Metadata.
  • Refactor readdirplus.

merged #4611

@ho-229 ho-229 marked this pull request as ready for review May 17, 2024 08:08
@ho-229 ho-229 requested review from Xuanwo and PsiACE as code owners May 17, 2024 08:08
@ho-229 ho-229 changed the title fix: ofs write behavior [wip] fix: ofs write behavior May 17, 2024
@ho-229
Copy link
Contributor Author

ho-229 commented May 21, 2024

cc @Xuanwo, PTAL

bin/ofs/src/fuse.rs Outdated Show resolved Hide resolved
bin/ofs/src/fuse.rs Outdated Show resolved Hide resolved
bin/ofs/src/fuse.rs Outdated Show resolved Hide resolved
drop(file);

let mut file = File::open(&path).await.unwrap();
thread::sleep(Duration::from_secs(1));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't make sense to sleep 1s to make tests pass. We should fix it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tracked at #4636

Copy link
Member

@Xuanwo Xuanwo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for your effort!

@Xuanwo Xuanwo merged commit 9862a1d into apache:main May 23, 2024
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants