- yp2::RouterChain router;
- yp2::FilterFrontendNet filter_front;
- filter_front.listen_address() = "unix:socket";
- filter_front.listen_duration() = 2; // listen a short time only
- router.rule(filter_front);
+ mp::RouterChain router;
+
+ // put in frontend first
+ mp::filter::FrontendNet filter_front;
+
+ std::vector <std::string> ports;
+ ports.insert(ports.begin(), "unix:socket");
+ filter_front.ports() = ports;
+ filter_front.listen_duration() = 1; // listen a short time only
+ router.append(filter_front);