Repository navigation
crimson/seatore: rework lba_manager to use LBACursor rather than LBAMapping - #66245
Conversation
|
Replaces #66208 to avoid slashes in branch name. |
b0a0309 to
9c4454b
Compare
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
9c4454b to
9c81ef3
Compare
9c81ef3 to
fffbc62
Compare
|
LGTM otherwise:-) |
| @@ -856,46 +856,39 @@ BtreeLBAManager::_update_mapping_ret | |||
| BtreeLBAManager::_update_mapping( | |||
| Transaction &t, | |||
| LBACursor &cursor, | |||
| update_func_t &&f, | |||
| update_func_t f, | |||
There was a problem hiding this comment.
Should LBACursor &cursor param be used by value or LBACursorRef as its passed to a coroutine?
There was a problem hiding this comment.
It's owner is responsible for ensuring lifetime. I could have chosen to pass it as a value, but this is safe provided that the caller handles it correctly.
| return std::move(ret); | ||
| }); | ||
| }); | ||
|
|
There was a problem hiding this comment.
LBABtree& btree passed as reference to BtreeLBAManager::get_cursors coroutine. The users of this method would be moved out of the with_btree_state.
There was a problem hiding this comment.
Yes, it's a reference, so the caller is responsible for lifetime. I don't see any problematic callers? Looks like
BtreeLBAManager::get_cursors(
Transaction &t,
laddr_t laddr,
extent_len_t length)
retains btree as an autovariable during the call?
There was a problem hiding this comment.
The caller of this override of get_cursors is:
BtreeLBAManager::resolve_indirect_cursor(
op_context_t c,
LBABtree& btree,
const LBACursor &indirect_cursor)
which takes LBABtree as a reference, it looks like resolve_indirect_cursor users would retain btree correctly.
However, wouldn't this be tricky for new users to know that they should be responsible for retaining lifetime? Passing a <type>Ref seems to help us avoid this kind of issues. I understand there are specific cases such as Transaction &t raw ref usage. But in other cases, is there a reason not to default to <type>Ref to make ownership and lifetime handling easier?
fffbc62 to
18e1ce1
Compare
|
Just waiting on testing. |
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
Signed-off-by: Samuel Just <[email protected]>
…iant Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
…ursorRef Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
…te_mapping return value Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
…pdate_mapping_ret_bare_t Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
…te test case Signed-off-by: Samuel Just <[email protected]>
Signed-off-by: Samuel Just <[email protected]>
0e44968 to
dfda0da
Compare
Show available Jenkins commands
jenkins test classic perfJenkins Job | Jenkins Job Definitionjenkins test crimson perfJenkins Job | Jenkins Job Definitionjenkins test signedJenkins Job | Jenkins Job Definitionjenkins test make checkJenkins Job | Jenkins Job Definitionjenkins test make check arm64Jenkins Job | Jenkins Job Definitionjenkins test submodulesJenkins Job | Jenkins Job Definitionjenkins test dashboardJenkins Job | Jenkins Job Definitionjenkins test dashboard cephadmJenkins Job | Jenkins Job Definitionjenkins test apiJenkins Job | Jenkins Job Definitionjenkins test docsReadTheDocs | Github Workflow Definitionjenkins test ceph-volume allJenkins Jobs | Jenkins Jobs Definitionjenkins test windowsJenkins Job | Jenkins Job Definitionjenkins test rook e2eJenkins Job | Jenkins Job DefinitionYou must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.