OpenSDN source code
vxlan.cc
Go to the documentation of this file.
1 /*
2  * Copyright (c) Juniper Networks, Inc. All rights reserved.
3  * Copyright Contributors to the OpenSDN project
4  */
5 
6 #include <cmn/agent_cmn.h>
8 #include <oper/vrf.h>
9 #include <oper/vn.h>
10 #include <oper/nexthop.h>
11 #include <oper/vxlan.h>
12 #include <oper/mirror_table.h>
13 #include <oper/agent_sandesh.h>
14 #include <oper/mpls.h>
15 
16 using namespace std;
17 
19  if (vxlan_id_ == VxLanTable::kInvalidvxlan_id) {
20  return;
21  }
22 }
23 
25  VxLanIdKey *key = new VxLanIdKey(vxlan_id_);
26  return DBEntryBase::KeyPtr(key);
27 }
28 
29 void VxLanId::SetKey(const DBRequestKey *k) {
30  const VxLanIdKey *key = static_cast<const VxLanIdKey *>(k);
31  vxlan_id_ = key->vxlan_id();
32 }
33 
35  Register();
36 }
37 
39  interface_listener_id_ = agent()->interface_table()->Register(
40  boost::bind(&VxLanTable::VmInterfaceNotify, this, _1, _2));
41 
42 }
43 
45  agent()->interface_table()->Unregister(interface_listener_id_);
46 }
47 
49  const Interface *intf = static_cast<const Interface *>(e);
50  const VmInterface *vm_itf;
51  bool composite_nh_modified = false;
52  if (intf->type() != Interface::VM_INTERFACE) {
53  return;
54  }
55 
56  vm_itf = static_cast<const VmInterface *>(intf);
57 
58  if (vm_itf->vn() == NULL) {
59  return;
60  }
61 
62  const VnEntry *vn = vm_itf->vn();
63  if (!vn->mirror_destination()) {
64  return;
65  }
66 
67  ComponentNHKeyPtr nh_key(new ComponentNHKey(vm_itf->label(),vm_itf->GetUuid(),
69  vm_itf->vm_mac()));
70  // if the interface deleted remove the entry from map
71  // else add it to composite NH list
72  if (intf->IsDeleted() || ((vm_itf->l2_active() == false) &&
73  (vm_itf->ipv4_active() == false) &&
74  (vm_itf->ipv6_active() == false))) {
75  composite_nh_modified = DeleteCompositeNH(vm_itf->vxlan_id(), nh_key);
76  } else {
77  composite_nh_modified = AddCompositeNH(vm_itf->vxlan_id(), nh_key);
78  // In case an older NH exists for the same interface, which was added based on
79  // a different vmi->label(), we need to delete that before adding the new one,
80  // otherwise there traffic will be duplicated on the output interface, since
81  // both the older and newer NH (policy disabled/enabled) point to the same
82  // output interface
83  if (composite_nh_modified && vm_itf->label_op() != MplsTable::kInvalidLabel) {
84  ComponentNHKeyPtr nh_key_op(
85  new ComponentNHKey(vm_itf->label_op(),vm_itf->GetUuid(),
87  vm_itf->vm_mac()));
88  DeleteCompositeNH(vm_itf->vxlan_id(), nh_key_op);
89  }
90  }
91 
92  if (composite_nh_modified) {
93  Create(vm_itf->vxlan_id(), vm_itf->vrf()->GetName(),
95  vm_itf->learning_enabled(), !vn->vxlan_routing_vn());
96  }
97  return;
98 }
99 
100 bool VxLanTable::DeleteCompositeNH(uint32_t vxlan_id,
101  ComponentNHKeyPtr nh_key) {
102  VxlanCompositeNHList::iterator it = vxlan_composite_nh_map_.find(vxlan_id);
103  if (it != vxlan_composite_nh_map_.end()) {
104  ComponentNHKeyList::iterator list_it = it->second.begin();
105  for (; list_it != it->second.end(); list_it++) {
106  if (*list_it == NULL) {
107  continue;
108  }
109  if (**list_it == *nh_key) {
110  // release the ComponentNHKeyPtr
111  (*list_it).reset();
112  it->second.erase(list_it);
113  return true;
114  }
115  }
116  return false;
117  }
118  return false;
119 }
120 
121 bool VxLanTable::AddCompositeNH(uint32_t vxlan_id, ComponentNHKeyPtr nh_key) {
122  VxlanCompositeNHList::iterator it = vxlan_composite_nh_map_.find(vxlan_id);
123  if (it != vxlan_composite_nh_map_.end()) {
124  ComponentNHKeyList::const_iterator list_it = it->second.begin();
125  for (; list_it != it->second.end(); list_it++) {
126  if (*list_it == NULL) {
127  continue;
128  }
129  if (**list_it == *nh_key) {
130  // already there no modification
131  return false;
132  }
133  }
134  it->second.push_back(nh_key);
135  return true;
136  }
137  ComponentNHKeyList list;
138  list.push_back(nh_key);
139  vxlan_composite_nh_map_.insert(VxlanCompositeNHEntry(vxlan_id, list));
140  return true;
141 }
142 
143 
144 std::unique_ptr<DBEntry> VxLanTable::AllocEntry(const DBRequestKey *k) const {
145  const VxLanIdKey *key = static_cast<const VxLanIdKey *>(k);
146  VxLanId *vxlan_id = new VxLanId(key->vxlan_id());
147  return std::unique_ptr<DBEntry>(static_cast<DBEntry *>(vxlan_id));
148 }
149 
151  agent()->ConcurrencyCheck();
152  DBTablePartition *tpart =
153  static_cast<DBTablePartition *>(GetTablePartition(req.key.get()));
154  Input(tpart, NULL, &req);
155 }
156 
158  VxLanIdKey *key = static_cast<VxLanIdKey *>(req->key.get());
159  VxLanId *vxlan_id = new VxLanId(key->vxlan_id());
160 
161  ChangeHandler(vxlan_id, req);
162  vxlan_id->SendObjectLog(this, AgentLogEvent::ADD);
163  return vxlan_id;
164 }
165 
166 bool VxLanTable::OnChange(DBEntry *entry, const DBRequest *req) {
167  bool ret;
168  VxLanId *vxlan_id = static_cast<VxLanId *>(entry);
169  ret = ChangeHandler(vxlan_id, req);
170  vxlan_id->SendObjectLog(this, AgentLogEvent::CHANGE);
171  return ret;
172 }
173 
174 // No Change expected for vxlan_id vxlan_id
175 bool VxLanTable::ChangeHandler(VxLanId *vxlan_id, const DBRequest *req) {
176  bool ret = false;
177  VxLanIdData *data = static_cast<VxLanIdData *>(req->data.get());
178 
180  NextHop *nh;
181  // if VN is enabled with mirror destination point the vxlan nh
182  // to CompositeNH
183  if (data->mirror_destination()) {
184  VxlanCompositeNHList::iterator it =
185  vxlan_composite_nh_map_.find(vxlan_id->vxlan_id());
186  if (it != vxlan_composite_nh_map_.end()) {
187  CompositeNHKey nh_key(Composite::L2INTERFACE, false, it->second,
188  data->vrf_name());
189  nh = static_cast<NextHop *>
191  } else {
192  // vm interface notification arraived at so create dummy CompositeNH
193  ComponentNHKeyPtr nh_ptr;
194  nh_ptr.reset();
195  ComponentNHKeyList list;
196  list.push_back(nh_ptr);
197  CompositeNHKey nh_key(Composite::L2INTERFACE, false, list,
198  data->vrf_name());
199  nh = static_cast<NextHop *>
200  (agent()->nexthop_table()->FindActiveEntry(&nh_key));
201  }
202  } else {
203  VrfNHKey nh_key(data->vrf_name(), false, data->bridge());
204  nh = static_cast<NextHop *>
206  }
207 
208  if (vxlan_id->nh_ != nh) {
209  vxlan_id->nh_ = nh;
210  ret = true;
211  }
212 
213  return ret;
214 }
215 
216 bool VxLanTable::Delete(DBEntry *entry, const DBRequest *req) {
217  VxLanId *vxlan_id = static_cast<VxLanId *>(entry);
218  vxlan_id->SendObjectLog(this, AgentLogEvent::DEL);
219  return true;
220 }
221 
222 VxLanId *VxLanTable::Find(uint32_t vxlan_id) {
223  VxLanIdKey key(vxlan_id);
224  return static_cast<VxLanId *>(FindActiveEntry(&key));
225 }
226 
227 VxLanId *VxLanTable::FindNoLock(uint32_t vxlan_id) {
228  VxLanIdKey key(vxlan_id);
229  return static_cast<VxLanId *>(FindActiveEntryNoLock(&key));
230 }
231 
233  const VxLanId *vxlan_id = static_cast<const VxLanId *>(e);
234  Delete(vxlan_id->vxlan_id());
235 }
236 
237 // Follows semantics defined for the ConfigTree in vxlan.h
238 // Return values:
239 // - vxlan dbentry if "vn" is "active"
240 // - NULL if "vn" is "inactive"
241 VxLanId *VxLanTable::Locate(uint32_t vxlan_id, const boost::uuids::uuid &vn,
242  const std::string &vrf, bool flood_unknown_unicast,
243  bool mirror_destination, bool learning_enabled,
244  bool bridge) {
245  // Treat a request without VRF as delete of config entry
246  if (vrf.empty()) {
247  Delete(vxlan_id, vn);
248  return NULL;
249  }
250 
251  // If there are no config-entries persent for the vxlan,
252  // - Add the config-entry and make it active
253  // - Create VxLan entry
254  ConfigTree::iterator it = config_tree_.lower_bound(
255  ConfigKey(vxlan_id, boost::uuids::nil_uuid()));
256 
257  if (it == config_tree_.end() || it->first.vxlan_id_ != vxlan_id) {
258  config_tree_.insert(make_pair(ConfigKey(vxlan_id, vn),
259  ConfigEntry(vrf, flood_unknown_unicast,
260  true, mirror_destination,
261  bridge)));
262  Create(vxlan_id, vrf, flood_unknown_unicast, mirror_destination,
263  learning_enabled, bridge);
264  return Find(vxlan_id);
265  }
266 
267  // Handle change to existing config-entry
268  it = config_tree_.find(ConfigKey(vxlan_id, vn));
269  if (it != config_tree_.end()) {
270  it->second.vrf_ = vrf;
271  it->second.flood_unknown_unicast_ = flood_unknown_unicast;
272  it->second.mirror_destination_ = mirror_destination;
273  it->second.learning_enabled_ = learning_enabled;
274  it->second.bridge_ = bridge;
275 
276  // If entry is active, update vxlan dbentry with new information
277  if (it->second.active_) {
278  Create(vxlan_id, vrf, flood_unknown_unicast, mirror_destination,
279  learning_enabled, bridge);
280  return Find(vxlan_id);
281  }
282  // If entry inactive, return NULL
283  return NULL;
284  }
285 
286  // Entry not present, add it to config-tree
287  config_tree_.insert(make_pair(ConfigKey(vxlan_id, vn),
288  ConfigEntry(vrf, flood_unknown_unicast,
289  false, mirror_destination,
290  bridge)));
291  // Return NULL since the VN is active
292  return NULL;
293 }
294 
295 VxLanId *VxLanTable::Delete(uint32_t vxlan_id, const boost::uuids::uuid &vn) {
296  ConfigTree::iterator it = config_tree_.find(ConfigKey(vxlan_id, vn));
297  // Entry not found
298  if (it == config_tree_.end()) {
299  return NULL;
300  }
301 
302  // If the entry is active and getting deleted, make new "active" entry
303  bool active = it->second.active_;
304  config_tree_.erase(it);
305  if (active == false)
306  return NULL;
307 
308  // Make first entry as active
309  it = config_tree_.lower_bound(
310  ConfigKey(vxlan_id, boost::uuids::nil_uuid()));
311 
312  if (it == config_tree_.end() || it->first.vxlan_id_ != vxlan_id)
313  return NULL;
314 
315  it->second.active_ = true;
316  Create(vxlan_id, it->second.vrf_, it->second.flood_unknown_unicast_,
317  it->second.mirror_destination_, it->second.learning_enabled_,
318  it->second.bridge_);
319  agent()->vn_table()->ResyncReq(it->first.vn_);
320  return NULL;
321 }
322 
323 DBTableBase *VxLanTable::CreateTable(DB *db, const std::string &name) {
324  VxLanTable *table = new VxLanTable(db, name);
325  table->Init();
326  return table;
327 }
328 
329 void VxLanTable::Create(uint32_t vxlan_id, const string &vrf_name,
330  bool flood_unknown_unicast, bool mirror_destination,
331  bool learning_enable, bool bridge) {
333  if (mirror_destination) {
334  VxlanCompositeNHList::iterator it =
335  vxlan_composite_nh_map_.find(vxlan_id);
336  if (it != vxlan_composite_nh_map_.end()) {
337  nh_req.key.reset(new CompositeNHKey(Composite::L2INTERFACE, false,
338  it->second, vrf_name));
339  } else {
340  ComponentNHKeyPtr nh_ptr;
341  nh_ptr.reset();
342  ComponentNHKeyList list;
343  list.push_back(nh_ptr);
344  nh_req.key.reset(new CompositeNHKey(Composite::L2INTERFACE, false,
345  list, vrf_name));
346  }
347  nh_req.data.reset(new CompositeNHData());
348  } else {
349  nh_req.key.reset(new VrfNHKey(vrf_name, false, bridge));
350  nh_req.data.reset(new VrfNHData(flood_unknown_unicast, learning_enable,
351  false));
352  }
354  req.key.reset(new VxLanIdKey(vxlan_id));
355  req.data.reset(new VxLanIdData(vrf_name, nh_req, mirror_destination,
356  bridge));
357  Process(req);
358  return;
359 }
360 
361 void VxLanTable::Delete(uint32_t vxlan_id) {
363  req.key.reset(new VxLanIdKey(vxlan_id));
364  req.data.reset(NULL);
365  VxlanCompositeNHList::iterator it = vxlan_composite_nh_map_.find(vxlan_id);
366  if (it != vxlan_composite_nh_map_.end()) {
367  vxlan_composite_nh_map_.erase(it);
368  }
369  Process(req);
370 }
371 
372 bool VxLanId::DBEntrySandesh(Sandesh *sresp, std::string &name) const {
373  VxLanResp *resp = static_cast<VxLanResp *>(sresp);
374 
375  VxLanSandeshData data;
376  data.set_vxlan_id(vxlan_id_);
377  nh_->SetNHSandeshData(data.nh);
378  std::vector<VxLanSandeshData> &list =
379  const_cast<std::vector<VxLanSandeshData>&>(resp->get_vxlan_list());
380  list.push_back(data);
381 
382  return true;
383 }
384 
386  AgentLogEvent::type event) const {
387  VxLanObjectLogInfo info;
388  string str, nh_type;
389 
390  info.set_vxlan_id((int)vxlan_id_);
391  switch (event) {
392  case AgentLogEvent::ADD:
393  str.assign("Addition ");
394  break;
395  case AgentLogEvent::DEL:
396  str.assign("Deletion ");
397  info.set_event(str);
398  OPER_TRACE_ENTRY(VxLan, table, info);
399  return;
400  case AgentLogEvent::CHANGE:
401  str.assign("Modification ");
402  break;
403  default:
404  str.assign("Unknown");
405  break;
406  }
407  info.set_event(str);
408  const NextHop *nh = nexthop();
409  if (nh != NULL) {
410  //const VrfNH *vrf_nh;
411  switch(nh->GetType()) {
412  case NextHop::VRF: {
413  nh_type.assign("VRF");
414  const VrfNH *vrf_nh = static_cast<const VrfNH *>(nh);
415  info.set_vrf_name(vrf_nh->GetVrf()->GetName());
416  break;
417  }
418  default:
419  nh_type.assign("unknown");
420  break;
421  }
422  }
423  info.set_nh_type(nh_type);
424  OPER_TRACE_ENTRY(VxLan, table, info);
425 }
426 
427 void VxLanReq::HandleRequest() const {
428  AgentSandeshPtr sand(new AgentVxLanSandesh(context(), get_vxlan_id()));
429  sand->DoSandesh(sand);
430 }
431 
433  const std::string &context) {
434  return AgentSandeshPtr(new AgentVxLanSandesh(context,
435  args->GetString("vxlan_id")));
436 }
437 
439 // Sandesh routines to dump config tree
441 class VxLanConfigSandeshTask : public Task {
442  public:
443  VxLanConfigSandeshTask(Agent *agent, uint32_t vxlan_id, const string &vn,
444  const string &active, const string &context) :
445  Task(agent->task_scheduler()->GetTaskId(AGENT_SANDESH_TASKNAME), 0),
446  agent_(agent), vxlan_id_(vxlan_id), vn_(vn), active_(active),
447  context_(context) { }
449  virtual bool Run();
450  std::string Description() const { return "VxLanConfigSandeshTask"; }
451 
452  private:
454  uint32_t vxlan_id_;
455  string vn_;
456  string active_;
457  string context_;
459 };
460 
462  VxLanConfigResp *resp = new VxLanConfigResp();
463  vector<VxLanConfigEntry> &list =
464  const_cast<vector<VxLanConfigEntry>&>(resp->get_vxlan_config_entries());
465 
466  boost::uuids::uuid u = boost::uuids::nil_uuid();
467  if (vn_.empty() == false) {
468  u = StringToUuid(vn_);
469  }
470 
471  const VxLanTable::ConfigTree &tree = agent_->vxlan_table()->config_tree();
472  VxLanTable::ConfigTree::const_iterator it = tree.begin();
473  while (it != tree.end()) {
474  VxLanConfigEntry entry;
475  if (vxlan_id_ != 0) {
476  if (vxlan_id_ != it->first.vxlan_id_) {
477  it++;
478  continue;
479  }
480  }
481 
482  if (u != boost::uuids::nil_uuid() && u != it->first.vn_) {
483  it++;
484  continue;
485  }
486 
487  if (active_.empty() == false) {
488  if ((active_ == "true" || active_ == "yes" || active_ == "active")
489  && (it->second.active_ != true)) {
490  it++;
491  continue;
492  }
493 
494  if ((active_ == "false" || active_ == "no" || active_ == "inactive")
495  && (it->second.active_ != false)) {
496  it++;
497  continue;
498  }
499  }
500 
501  entry.set_vxlan_id(it->first.vxlan_id_);
502  entry.set_vn_uuid(UuidToString(it->first.vn_));
503  entry.set_vrf(it->second.vrf_);
504  entry.set_flood_unknown_unicast(it->second.flood_unknown_unicast_);
505  entry.set_active(it->second.active_);
506  list.push_back(entry);
507  it++;
508  }
509  resp->set_context(context_);
510  resp->set_more(false);
511  resp->Response();
512  return true;
513 }
514 
515 void VxLanConfigReq::HandleRequest() const {
516  Agent *agent = Agent::GetInstance();
518  new VxLanConfigSandeshTask(agent, get_vxlan_id(), get_vn(),
519  get_active(), context());
520  agent->task_scheduler()->Enqueue(task);
521 }
#define AGENT_SANDESH_TASKNAME
Definition: agent.h:302
class boost::shared_ptr< AgentSandesh > AgentSandeshPtr
Definition: agent_db.h:21
#define OPER_TRACE_ENTRY(obj, table,...)
Definition: agent_db.h:237
AgentDBEntry * FindActiveEntry(const DBEntry *key)
Definition: agent_db.cc:111
std::string GetString(const std::string &key) const
Definition: agent.h:361
TaskScheduler * task_scheduler() const
Definition: agent.h:1123
NextHopTable * nexthop_table() const
Definition: agent.h:478
static Agent * GetInstance()
Definition: agent.h:439
std::unique_ptr< DBRequestKey > KeyPtr
Definition: db_entry.h:25
bool IsDeleted() const
Definition: db_entry.h:49
void Init()
Definition: db_table.cc:414
Definition: db.h:25
@ VM_INTERFACE
Definition: interface.h:38
bool ipv6_active() const
Definition: interface.h:120
bool l2_active() const
Definition: interface.h:125
VrfEntry * vrf() const
Definition: interface.h:118
bool ipv4_active() const
Definition: interface.h:119
uint32_t label() const
Definition: interface.h:130
const boost::uuids::uuid & GetUuid() const
Definition: interface.h:116
Type type() const
Definition: interface.h:115
static const uint32_t kInvalidLabel
Definition: mpls.h:102
void Process(DBRequest &req)
Definition: nexthop.cc:368
@ VRF
Definition: nexthop.h:351
Type GetType() const
Definition: nexthop.h:406
void Enqueue(Task *task)
Enqueues a task for running. Starts task if all policy rules are met else puts task in waitq....
Definition: task.cc:662
Task is a class to describe a computational task within OpenSDN control plane applications....
Definition: task.h:82
int vxlan_id() const
bool learning_enabled() const
uint32_t label_op() const
const MacAddress & vm_mac() const
const VnEntry * vn() const
Definition: vn.h:152
const bool mirror_destination() const
Definition: vn.h:209
bool vxlan_routing_vn() const
Definition: vn.h:260
bool flood_unknown_unicast() const
Definition: vn.h:203
const string & GetName() const
Definition: vrf.h:104
const VrfEntry * GetVrf() const
Definition: nexthop.h:1445
VxLanConfigSandeshTask(Agent *agent, uint32_t vxlan_id, const string &vn, const string &active, const string &context)
Definition: vxlan.cc:443
uint32_t vxlan_id_
Definition: vxlan.cc:454
virtual bool Run()
Code to execute in a task. Returns true if task is completed. Return false to reschedule the task.
Definition: vxlan.cc:461
DISALLOW_COPY_AND_ASSIGN(VxLanConfigSandeshTask)
std::string Description() const
Gives a description of the task.
Definition: vxlan.cc:450
bool bridge() const
Definition: vxlan.h:71
bool mirror_destination() const
Definition: vxlan.h:70
string & vrf_name()
Definition: vxlan.h:68
DBRequest & nh_req()
Definition: vxlan.h:69
uint32_t vxlan_id() const
Definition: vxlan.h:50
Definition: vxlan.h:14
virtual ~VxLanId()
Definition: vxlan.cc:18
NextHopRef nh_
Definition: vxlan.h:40
virtual KeyPtr GetDBRequestKey() const
Definition: vxlan.cc:24
void SendObjectLog(const AgentDBTable *table, AgentLogEvent::type event) const
Definition: vxlan.cc:385
virtual void SetKey(const DBRequestKey *key)
Definition: vxlan.cc:29
uint32_t vxlan_id() const
Definition: vxlan.h:27
bool DBEntrySandesh(Sandesh *sresp, std::string &name) const
Definition: vxlan.cc:372
virtual bool Delete(DBEntry *entry, const DBRequest *req)
Definition: vxlan.cc:216
virtual AgentSandeshPtr GetAgentSandesh(const AgentSandeshArguments *args, const std::string &context)
Definition: vxlan.cc:432
bool ChangeHandler(VxLanId *vxlan_id, const DBRequest *req)
Definition: vxlan.cc:175
std::map< ConfigKey, ConfigEntry, ConfigKey > ConfigTree
Definition: vxlan.h:138
virtual bool OnChange(DBEntry *entry, const DBRequest *req)
Definition: vxlan.cc:166
VxLanId * Find(uint32_t vxlan_id)
Definition: vxlan.cc:222
void Shutdown()
Definition: vxlan.cc:44
static DBTableBase * CreateTable(DB *db, const std::string &name)
Definition: vxlan.cc:323
std::pair< uint32_t, ComponentNHKeyList > VxlanCompositeNHEntry
Definition: vxlan.h:140
void Initialize()
Definition: vxlan.cc:34
virtual DBEntry * Add(const DBRequest *req)
Definition: vxlan.cc:157
void Create(uint32_t vxlan_id, const std::string &vrf_name, bool flood_unknown_unicast, bool mirror_destination, bool learning_enabled, bool bridge)
Definition: vxlan.cc:329
virtual void OnZeroRefcount(AgentDBEntry *e)
Definition: vxlan.cc:232
bool AddCompositeNH(uint32_t vxlan_id, ComponentNHKeyPtr nh_key)
Definition: vxlan.cc:121
VxLanId * Locate(uint32_t vxlan_id, const boost::uuids::uuid &vn, const std::string &vrf, bool flood_unknown_unicast, bool mirror_destination, bool learning_enabled, bool bridge)
Definition: vxlan.cc:241
VxLanId * FindNoLock(uint32_t vxlan_id)
Definition: vxlan.cc:227
virtual std::unique_ptr< DBEntry > AllocEntry(const DBRequestKey *k) const
Definition: vxlan.cc:144
bool DeleteCompositeNH(uint32_t vxlan_id, ComponentNHKeyPtr nh_key)
Definition: vxlan.cc:100
static const uint32_t kInvalidvxlan_id
Definition: vxlan.h:141
void Process(DBRequest &req)
Definition: vxlan.cc:150
void VmInterfaceNotify(DBTablePartBase *partition, DBEntryBase *e)
Definition: vxlan.cc:48
void Register()
Definition: vxlan.cc:38
uint8_t type
Definition: load_balance.h:2
boost::shared_ptr< const ComponentNHKey > ComponentNHKeyPtr
Definition: nexthop.h:1640
std::vector< ComponentNHKeyPtr > ComponentNHKeyList
Definition: nexthop.h:1642
static boost::uuids::uuid StringToUuid(const std::string &str)
Definition: string_util.h:146
static std::string UuidToString(const boost::uuids::uuid &id)
Definition: string_util.h:139
@ L2INTERFACE
Definition: nexthop.h:1592
@ DB_ENTRY_DELETE
Definition: db_table.h:40
@ DB_ENTRY_ADD_CHANGE
Definition: db_table.h:39
std::unique_ptr< DBRequestKey > key
Definition: db_table.h:49
std::unique_ptr< DBRequestData > data
Definition: db_table.h:50
Definition: task_int.h:11
boost::uuids::uuid uuid