private void processRoute(final DOMDataWriteTransaction tx, final RIBSupport ribSupport, final AbstractImportPolicy policy, final YangInstanceIdentifier routesPath, final DataTreeCandidateNode route) {
LOG.debug("Process route {}", route);
+ final YangInstanceIdentifier routeId = ribSupport.routePath(routesPath, route.getIdentifier());
switch (route.getModificationType()) {
case DELETE:
- tx.delete(LogicalDatastoreType.OPERATIONAL, routesPath.node(route.getIdentifier()));
+ tx.delete(LogicalDatastoreType.OPERATIONAL, routeId);
break;
case UNMODIFIED:
// No-op
break;
case SUBTREE_MODIFIED:
case WRITE:
- final YangInstanceIdentifier routeId = ribSupport.routePath(routesPath, route.getIdentifier());
tx.put(LogicalDatastoreType.OPERATIONAL, routeId, route.getDataAfter().get());
// Lookup per-table attributes from RIBSupport
final ContainerNode advertisedAttrs = (ContainerNode) NormalizedNodes.findNode(route.getDataAfter(), ribSupport.routeAttributesIdentifier()).orNull();