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
rbd-mirror: image deletions should be handled by assigned instance #14832
Conversation
@@ -175,9 +175,6 @@ class BootstrapRequest : public BaseRequest { | |||
|
|||
bufferlist m_out_bl; | |||
|
|||
void get_local_image_id(); | |||
void handle_get_local_image_id(int r); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
need to update the state diagram
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ack
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
This state machine will be invoked before the bootstrap state machine and will be responsible for detecting if the local image is already primary or if it needs to be deleted. Signed-off-by: Jason Dillaman <dillaman@redhat.com>
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
52052a5
to
cbe469f
Compare
@@ -335,7 +336,8 @@ void ImageReplayer<I>::add_remote_image(const std::string &mirror_uuid, | |||
|
|||
template <typename I> | |||
void ImageReplayer<I>::remove_remote_image(const std::string &mirror_uuid, | |||
const std::string &image_id) { | |||
const std::string &image_id, | |||
bool schedule_delete) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: you might want to use spaces vs tabs here
@@ -109,7 +109,8 @@ class ImageReplayer { | |||
const std::string &remote_image_id, | |||
librados::IoCtx &remote_io_ctx); | |||
void remove_remote_image(const std::string &remote_mirror_uuid, | |||
const std::string &remote_image_id); | |||
const std::string &remote_image_id, | |||
bool schedule_delete); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tabs vs spaces
image_replayer->remove_remote_image(peer_mirror_uuid, peer_image_id); | ||
if (!peer_mirror_uuid.empty()) { | ||
image_replayer->remove_remote_image(peer_mirror_uuid, peer_image_id, | ||
schedule_delete); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tabs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
No description provided.