Skip to content

libcephfs: Nonblocking io#48038

Merged
vshankar merged 13 commits intoceph:mainfrom
ffilz:nonblocking-io
Jul 25, 2023
Merged

libcephfs: Nonblocking io#48038
vshankar merged 13 commits intoceph:mainfrom
ffilz:nonblocking-io

Conversation

@ffilz
Copy link
Contributor

@ffilz ffilz commented Sep 9, 2022

This replaces #44991 (async I/O).

This tests as working with Ganesha. I renamed to nonblocking I/O because there was some confusion with Read_Sync_Async that looks a lot better as Read_Sync_Nonblocking. A unit test is included.

Contribution Guidelines

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows

@github-actions
Copy link

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

@cbodley cbodley changed the title Nonblocking io libcephfs: Nonblocking io Oct 3, 2022
@cbodley cbodley added the feature label Oct 3, 2022
@ljflores
Copy link
Member

@ffilz looks like this needs a rebase

@ffilz
Copy link
Contributor Author

ffilz commented Dec 6, 2022

@ffilz looks like this needs a rebase

Rebase pushed.

@vshankar
Copy link
Contributor

@ffilz We will target this post reef branching and give it enough time to bake in main branch.

@github-actions
Copy link

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

@mattbenjamin
Copy link
Contributor

mattbenjamin commented May 1, 2023

@vshankar I'm not certain, but it looks as if this PR hasn't gotten a single review comment from the cephfs team, in 6 months. We are depending on starting a process that allows ganesha devs to get ongoing attention from cephfs devs. Please try to get a review in?

@mattbenjamin
Copy link
Contributor

@ffilz this should probably get a rebase. More importantly, there are commits which lack your signed-off-by. Please address that, and try to address the make check failure, after rebasing.

@ffilz
Copy link
Contributor Author

ffilz commented May 3, 2023

@ffilz this should probably get a rebase. More importantly, there are commits which lack your signed-off-by. Please address that, and try to address the make check failure, after rebasing.

I did a rebase last week. The unsigned commit is something that hopefully isn't actually needed but I needed it to compile. It's got nothing to do with my code... I will remove that commit before expecting the pull request to be merged.

@ffilz
Copy link
Contributor Author

ffilz commented May 3, 2023

Clicking on the details for the make check failures doesn't lead to any insight on them...

@ffilz
Copy link
Contributor Author

ffilz commented Jul 14, 2023

OK, done that. Sorry.

Did you forget pushing?

No, I was in a hurry and didn't pay attention to the error message. It didn't go because the network connection for my VM was bunged up do to the fuse covering my office tripping (and thus killing my switch)...

Should be pushed now...

@vshankar
Copy link
Contributor

jenkins retest this please

@vshankar
Copy link
Contributor

jenkins test make check

@vshankar
Copy link
Contributor

The windows failure is a known issue right now.

Copy link
Contributor

@vshankar vshankar left a comment

Choose a reason for hiding this comment

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

@vshankar
Copy link
Contributor

jenkins test make check

1 similar comment
@vshankar
Copy link
Contributor

jenkins test make check

@vshankar
Copy link
Contributor

jenkins test windows

@vshankar
Copy link
Contributor

Windows jenkins failure fix: #52427

@vshankar
Copy link
Contributor

jenkins test windows

@vshankar
Copy link
Contributor

@ffilz please rebase and push - the windows failure has been fixed and merged.

ffilz added 13 commits July 24, 2023 11:49
For non-blocking I/O, we will want to be able to override
block_writes_upfront so rename the member cfg_block_writes_upfront and add
an option to pass block_writes_upfront as a parameter along with a member
access method so caller can pass cfg_block_writes_upfront.

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
These bits of code need to be invoked from a separate spot when we
introduce non-blocking I/O, so break them out now.

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Change waitfor_caps, waitfor_safe and waitfor_commit to Context list.

To make a non-blocking version of fsync (to be used for non-blocking write
and commit), we need to be able to signal an arbitrary Context on completion
of either of these lists.

add_nonblocking_onfinish_to_context_list Adds such a Context to the list.

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
The non-blocking flush requires us to be able to re-add to
wait_for_caps but if we simply add to the list, we get stuck in an
infinite loop. Add a wait_for_caps_pending list to add to, and then
when done signalling, we move the wait_for_caps_pending items onto the
wait_for_caps list.

Also in handle_cap_flush_ack(), we need to complete the caps flushing
before signalling since with non-blocking flush, we will be actually
examining the caps from the completion rather than signalling a
condition variable in the completion.

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
We will need the ability to do an non-blocking write that finishes with
fsync so we need non-blocking fsync.

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
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.

6 participants