| | |
| | | NodeCenter(const std::string &id, const Cleaner &cleaner, const steady_clock::duration offline_time, const steady_clock::duration kill_time) : |
| | | NodeCenter(id, cleaner, duration_cast<seconds>(offline_time).count(), duration_cast<seconds>(kill_time).count()) {} |
| | | |
| | | const std::string &id() const |
| | | { |
| | | return id_; |
| | | } // no need to lock. |
| | | // center name, no relative to shm. |
| | | const std::string &id() const { return id_; } |
| | | |
| | | //TODO maybe just return serialized string. |
| | | MsgCommonReply Register(const BHMsgHead &head, MsgRegister &msg) |
| | | { |
| | | if (msg.proc().proc_id() != head.proc_id()) { |
| | |
| | | printf("remove mq : %s\n", r ? "ok" : "failed"); |
| | | }; |
| | | |
| | | AddCenter("#center", gc); |
| | | AddCenter("#bhome_center", gc); |
| | | |
| | | for (auto &kv : Centers()) { |
| | | auto &info = kv.second; |