Skip to content
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

mimic: mgr: deadlock #28161

Merged
merged 2 commits into from Jul 10, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 0 additions & 3 deletions src/mgr/ActivePyModules.cc
Expand Up @@ -523,10 +523,7 @@ void ActivePyModules::set_store(const std::string &module_name,

Command set_cmd;
{
PyThreadState *tstate = PyEval_SaveThread();
Mutex::Locker l(lock);
PyEval_RestoreThread(tstate);

if (val) {
store_cache[global_key] = *val;
} else {
Expand Down
4 changes: 4 additions & 0 deletions src/mgr/BaseMgrModule.cc
Expand Up @@ -406,7 +406,9 @@ ceph_config_set(BaseMgrModule *self, PyObject *args)
if (value) {
val = value;
}
PyThreadState *tstate = PyEval_SaveThread();
self->py_modules->set_config(self->this_module->get_name(), key, val);
PyEval_RestoreThread(tstate);

Py_RETURN_NONE;
}
Expand Down Expand Up @@ -447,7 +449,9 @@ ceph_store_set(BaseMgrModule *self, PyObject *args)
if (value) {
val = value;
}
PyThreadState *tstate = PyEval_SaveThread();
self->py_modules->set_store(self->this_module->get_name(), key, val);
PyEval_RestoreThread(tstate);

Py_RETURN_NONE;
}
Expand Down