| | |
| | | } |
| | | // recv msgs to avoid memory leak. |
| | | auto default_ignore_msg = [](ShmSocket &sock, MsgI &imsg, BHMsgHead &head) { return true; }; |
| | | for (auto &p : sockets_) { |
| | | p->Start(default_ignore_msg); |
| | | } |
| | | SockNode().Start(default_ignore_msg); |
| | | // for (auto &p : sockets_) { |
| | | // p->Start(default_ignore_msg); |
| | | // } |
| | | } |
| | | |
| | | TopicNode::~TopicNode() |
| | |
| | | |
| | | BHAddress addr; |
| | | if (ClientQueryRPCTopic(request.topic(), addr, timeout_ms)) { |
| | | printf("node: %ld, topic dest: %ld\n", SockNode().id(), addr.mq_id()); |
| | | BHMsgHead head(InitMsgHead(GetType(request), proc_id(), ssn())); |
| | | AddRoute(head, sock.id()); |
| | | head.set_topic(request.topic()); |