]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
librbd: fix a bunch of issues with restarting RefreshRequest
authorIlya Dryomov <idryomov@gmail.com>
Fri, 2 Sep 2022 14:58:36 +0000 (16:58 +0200)
committerIlya Dryomov <idryomov@gmail.com>
Tue, 6 Sep 2022 18:22:05 +0000 (20:22 +0200)
commit0f5f3a297091ff81ed607a1c27ce16e5e5cbdfe0
tree2df1046ee5d27c2fc93b3fd6b13abe7ede1d4737
parent0c70d702382726c326d254fd1d5dfe8422a2fede
librbd: fix a bunch of issues with restarting RefreshRequest

Make RefreshRequest properly restartable, at least up until and including
V2_REFRESH_PARENT step:

- clear m_migration_spec when skipping GET_MIGRATION_HEADER
- don't rely on potentially stale m_incomplete_update on retry
- reset m_legacy_parent when retrying more than just V2_GET_PARENT
- don't rely on potentially stale m_parent_md.overlap and
  m_head_parent_overlap on retry
- clear m_metadata before fetching image metadata (but not before
  fetching pool metadata)
- clear m_op_features when skipping V2_GET_OP_FEATURES
- clear m_group_spec on EOPNOTSUPP error in V2_GET_GROUP
- reset m_legacy_snapshot when retrying more than just V2_GET_SNAPSHOTS
- don't rely on potentially stale m_snap_parents on retry

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit 6bd89ea119520cf5a45ac93b0e16edf35ddd4e57)
src/librbd/image/RefreshRequest.cc