OpenSDN source code
icmp_proto.cc
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2013 Juniper Networks, Inc. All rights reserved.
3  */
4 
5 #include <cmn/agent_cmn.h>
6 #include <init/agent_init.h>
7 #include <services/icmp_proto.h>
8 
9 IcmpProto::IcmpProto(Agent *agent, boost::asio::io_context &io) :
10  Proto(agent, "Agent::Services", PktHandler::ICMP, io) {
11  // limit the number of entries in the workqueue
13  work_queue_.SetBounded(true);
14 }
15 
17 }
18 
19 ProtoHandler *IcmpProto::AllocProtoHandler(boost::shared_ptr<PktInfo> info,
20  boost::asio::io_context &io) {
21  return new IcmpHandler(agent(), info, io);
22 }
uint32_t services_queue_limit()
Definition: agent_param.h:416
Definition: agent.h:360
AgentParam * params() const
Definition: agent.h:1226
virtual ~IcmpProto()
Definition: icmp_proto.cc:16
ProtoHandler * AllocProtoHandler(boost::shared_ptr< PktInfo > info, boost::asio::io_context &io)
Definition: icmp_proto.cc:19
IcmpProto(Agent *agent, boost::asio::io_context &io)
Definition: icmp_proto.cc:9
void SetBounded(bool bounded)
Definition: queue_task.h:200
void SetSize(size_t size)
Definition: queue_task.h:196
Definition: io_utils.cc:11