-void
-config::paxos_commit(unsigned instance, const std::string &value)
-{
- std::string m;
- std::vector<std::string> newmem;
- lock ml(cfg_mutex);
-
- members(value, newmem);
- tprintf("config::paxos_commit: %d: %s\n", instance,
- print_members(newmem).c_str());
-
- for (unsigned i = 0; i < mems.size(); i++) {
- tprintf("config::paxos_commit: is %s still a member?\n",
- mems[i].c_str());
- if (!isamember(mems[i], newmem) && me != mems[i]) {
- tprintf("config::paxos_commit: delete %s\n", mems[i].c_str());
- mgr.delete_handle(mems[i]);
+void config::paxos_commit(unsigned instance, const string &value) {
+ lock cfg_mutex_lock(cfg_mutex);
+
+ vector<string> newmem = members(value);
+ LOG("instance " << instance << ": " << newmem);
+
+ for (auto mem : mems) {
+ LOG("is " << mem << " still a member?");
+ if (!isamember(mem, newmem) && me != mem) {
+ LOG("delete " << mem);
+ invalidate_handle(mem);
+ //handle(mem).invalidate();