Merge pull request #21984 from liewegas/wip-24118

mon/MonClient: set configs via finisher

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
This commit is contained in:
Sage Weil 2018-05-16 16:04:34 -05:00 committed by GitHub
commit a65e72a0fb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -374,8 +374,10 @@ void MonClient::handle_monmap(MMonMap *m)
void MonClient::handle_config(MConfig *m)
{
ldout(cct,10) << __func__ << " " << *m << dendl;
cct->_conf->set_mon_vals(cct, m->config, config_cb);
m->put();
finisher.queue(new FunctionContext([this, m](int r) {
cct->_conf->set_mon_vals(cct, m->config, config_cb);
m->put();
}));
got_config = true;
map_cond.Signal();
}