Ask is moving to Stack Overflow and! Please use the "opendaylight" tag on either of these sites. This site is now in Read-Only mode

Revision history [back]

OK So I found a way to do this in Carbon MDSAL. Here's what I did:

In my DataTreeChangeListner<flowcapablenode>

       public class WakeupOnFlowCapableNode implements DataTreeChangeListener<FlowCapableNode> {
      public void onDataTreeChanged(Collection<DataTreeModification<FlowCapableNode>> modifications) {


    for (DataTreeModification<FlowCapableNode> modification : modifications) {

               if (modification.getRootNode().getModificationType() == ModificationType.WRITE) {

                           InstanceIdentifier<FlowCapableNode> ii = modification.getRootPath().getRootIdentifier();

            String nodeUri = ii.firstKeyOf(Node.class).getId().getValue();

                            // Now put the nodeUri into a map 
                            idMap.put(nodeUri, ii)


In my PacketIn listener I have

public void onPacketReceived(PacketReceived notification) {"onPacketReceived");
    NodeConnectorId nodeConnectorId = notification.getMatch().getInPort();
    // Get the node connector URI for the inbound packet.
    String nodeConnectorUri = nodeConnectorId.getValue();

The latter returns something like


I can strip off the last :1 and use the prefix to lookup the map entry in the DataTreeChangedListner.

Now I need to understand openflow URIs. What does openflow:1:1 mean?