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
mon:C_AckMarkedDown has not handled the Callback Arguments #29624
Conversation
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.
@NancySu05 thanks for your fix! could you revise the title of your commit message? as it reads like a bug report instead of the summary of your change.
see https://github.com/ceph/ceph/blob/master/SubmittingPatches.rst#3-describe-your-changes
also could you add a space after "Fixes:"?
i'd suggest use your full name as your user.name
of your git config. currently it's NancySu05.
src/mon/OSDMonitor.cc
Outdated
osdmon->dispatch(op); | ||
} else if(ECANCELED == r) { | ||
return; | ||
}else { |
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.
a space before else
.
Is dropping the message on ECANCELED ok? The osd is waiting for a reply to shutdown, right? Also, I don't see anywhere where waiting_for_finished_proposal contexts get an ECANCELED. |
The EAGAIN case looks right though I think. |
no. it does not wait for a reply. |
There's a timeout set in OSDService::prepare_to_stop to ensure that it shuts down on its own eventually, but it looks to me like OSD::ms_dispatch does handle the MSG_OSD_MARK_ME_DOWN reply from the mon by calling OSDService::got_stop_ack which moves the OSD on to STOPPING allowing it to finish shutting down more quickly. I'd guess that if ECANCELED is possible, some form of retry or reply to the OSD would be appropriate. |
oh, sorry! i was wrong. was checking |
neither can i. probably we can add an |
you idea is better,I have revised the submission |
|
I have made changes as suggested |
in C_AckMarkedDown,we add a process that handle _finish(int) Callback Arguments Fixes: https://tracker.ceph.com/issues/41217 Signed-off-by: NancySu05 <su_nan@inspur.com>
false)); // ACK itself does not request an ack | ||
void _finish(int r) override { | ||
if (r == 0) { | ||
MOSDMarkMeDown *m = static_cast<MOSDMarkMeDown*>(op->get_req()); |
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.
use auto
. less repeating this way. and could use the template variant of get_req()
. i.e.,
auto m = op->get_req<MOSDMarkMeDown>();
in C_AckMarkedDown, we add a process that handle _finish(int) Callback Arguments
Fixes: https://tracker.ceph.com/issues/41217
Signed-off-by: NancySu05 su_nan@inspur.com