]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
Merge pull request #51044 from kotreshhr/wip-59416-quincy
authorYuri Weinstein <yweinste@redhat.com>
Wed, 24 May 2023 14:29:08 +0000 (10:29 -0400)
committerGitHub <noreply@github.com>
Wed, 24 May 2023 14:29:08 +0000 (10:29 -0400)
quincy: mgr: Add one finisher thread per module

Reviewed-by: Kotresh HR <khiremat@redhat.com>
1  2 
src/mgr/ActivePyModules.cc
src/mgr/PyModuleRegistry.h

Simple merge
index 14b8339665a4276e4693bf344b4ea3236b8f3171,c0e951ed7b67ab6053c235b472453634a5c18ae5..e16b2830d910e8cbcf757a1bf443b7a6e49c090b
@@@ -221,9 -219,23 +221,19 @@@ public
  
    auto get_clients() const
    {
 -    std::scoped_lock l(lock);
 -    std::vector<entity_addrvec_t> v;
 -    for (const auto& p : clients) {
 -      v.push_back(p.second);
 -    }
 -    return v;
 +    std::lock_guard l(lock);
 +    return clients;
    }
  
+   bool is_module_active(const std::string &name) {
+     ceph_assert(active_modules);
+     return active_modules->module_exists(name);
+   }
+   auto& get_active_module_finisher(const std::string &name) {
+     ceph_assert(active_modules);
+     return active_modules->get_module_finisher(name);
+   }
    // <<< (end of ActivePyModules cheeky call-throughs)
  };