diff options
author | Sage Weil <sage@redhat.com> | 2018-12-19 01:05:36 +0100 |
---|---|---|
committer | Sage Weil <sage@redhat.com> | 2018-12-21 05:11:40 +0100 |
commit | 38a3a819973ba7937f4af48c636492585d6072a6 (patch) | |
tree | 288daf1d8eec7a89eafbe380a785da6569b98005 | |
parent | mon/MgrMonitor: make find_module_option handle localized option names (diff) | |
download | ceph-38a3a819973ba7937f4af48c636492585d6072a6.tar.xz ceph-38a3a819973ba7937f4af48c636492585d6072a6.zip |
mon/MgrMonitor: mark module options with FLAG_MGR
Signed-off-by: Sage Weil <sage@redhat.com>
-rw-r--r-- | src/common/options.h | 1 | ||||
-rw-r--r-- | src/mon/MgrMonitor.cc | 5 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/common/options.h b/src/common/options.h index ce5671729f7..7c58856a50f 100644 --- a/src/common/options.h +++ b/src/common/options.h @@ -116,6 +116,7 @@ struct Option { FLAG_STARTUP = 0x4, ///< option can only take effect at startup FLAG_CLUSTER_CREATE = 0x8, ///< option only has effect at cluster creation FLAG_CREATE = 0x10, ///< option only has effect at daemon creation + FLAG_MGR = 0x20, ///< option is a mgr module option }; struct size_t { diff --git a/src/mon/MgrMonitor.cc b/src/mon/MgrMonitor.cc index 9d749d26494..ae1476410ce 100644 --- a/src/mon/MgrMonitor.cc +++ b/src/mon/MgrMonitor.cc @@ -173,6 +173,7 @@ void MgrMonitor::update_from_paxos(bool *need_bootstrap) static_cast<Option::level_t>(j.second.level))); Option& opt = p.first->second; opt.set_flags(static_cast<Option::flag_t>(j.second.flags)); + opt.set_flag(Option::FLAG_MGR); opt.set_description(j.second.desc.c_str()); opt.set_long_description(j.second.long_desc.c_str()); for (auto& k : j.second.tags) { @@ -180,11 +181,11 @@ void MgrMonitor::update_from_paxos(bool *need_bootstrap) } for (auto& k : j.second.see_also) { if (i.module_options.count(k)) { - // another module option + // it's another module option misc_option_strings.push_back(string("mgr/") + i.name + "/" + k); opt.add_see_also(misc_option_strings.back().c_str()); } else { - // ceph option + // it's a native option opt.add_see_also(k.c_str()); } } |