Presentation is loading. Please wait.

Presentation is loading. Please wait.

Simplified Network Service Interfaces Sept 29 2014

Similar presentations

Presentation on theme: "Simplified Network Service Interfaces Sept 29 2014"— Presentation transcript:

1 Simplified Network Service Interfaces Sept 29 2014

2  Motivations  Use-cases  API Definitions  Design Considerations  Q/As Outline 2

3  Port Existing SDN Apps to OpenDaylight Project  Decrease Complexity for “Application” Writers  Provide Data Model and Infrastructure Independence  Eliminate Code Duplication  Provide an abstraction of Network Services from the underlying Data Model  Applications are burdened with searching, sorting, and filtering model objects in the datastore  Increase Performance for certain frequent data access .findNode is an O(n) operation  Build a flexible middleware service layer for evolving North- Bound API’s Motivations 3

4  Network Services API’s are a library of Data Access methods that allow middleware apps to create action-based semantics  Middleware apps want to interact with the control plane with action-based semantics, not network data semantics  ‘ block’, ‘allow’, ‘inspect’, ‘inject’, ‘redirect’, ‘copy’, ‘set quality {latency, bandwidth, loss}’  Network Middleware Apps: HP Network Optimizer HP Network Protector Network Service API’s Foundation for Evolving NBI’s 4

5 Network Service API’s SAL Layering NETCONF Node Host Link Topo Path Flow Packet Network Service API’s Node Data Store Host Link Topo Path Flow Packet Node Host Link Topo Path Flow Packet SNMP OpenFlow... API’s MD-SAL Providers Suppliers Protocols ??? Action Semantic API’s GBP... NBI’s Data Change NotificationsData Access Acknowledge that there are many levels at which “Applications” interact with controller functions. Network Service API’s are at a lower stratum than Intent level or Policy level NBI’s

6  Getting hosts by IP address On MD-SAL Today: DataBroker broker = session. getSalService(DataBroker.class); ReadOnlyTransaction tx = broker.newReadOnlyTransaction(); ListenableFuture future =, instanceIdentifier); Hosts hosts = future.get(); List salHosts = hosts.get(); List matchingHosts = new ArrayList (); for(Host host : salHosts ) { //if IP address matches //matchingHosts.add(host);... with a Simple API HostService ns; IpAddress addr = IpAddress.valueOf(""); List Hosts = ns.getHostsByIpAddress(addr);... App Code Example 6

7 One use case (in correct order) – install flow to rate limit on traffic from host-A (by IPv4 address) the moment host-A shows up: 1)Register to receive DataPath oper status: so App could build up knowledge base on list of DataPaths 2)Register to receive Host discovery 3)Receive host-A discovery: IPv4 address MAC address c.attached DataPath d.attached DataPath VLAN e.attached DataPath port 4)Send out MeterMod (some rate, and exceeding action) 5)Send out Barrier Request 6)Send out FlowMod (host-A IPv4 address, action to the meter previously installed) 7)Receive DataPath Barrier Response 8)Unregister to receive Host discovery– upon App uninstall 9)Unregister to receive DataPath oper status – upon App uninstall Simple App using Net Svc API’s 7 Fix this

8 Network Service API’s - Nodes 8 NodeService API’sMethod Get all NodesIterator getNodes() Get Nodes by filterIterator getNodes(NodeFilter filter) Get Node by IDNode getNode(NodeId id) Get Nodes by IP AddressSet getNodes(IpAddress NodeIp) Get Node by DPIDNode getNode(DataPathId dpid) Get Node by URINode getNode(URI uri) Get Nodes by DriverIterator getNodes(Class DriverClass) Get all interfaces on a NodeList getInterfaces(Node Node) Get an interface on a Node by interface IDInterface getInterface(NodeId NodeId, InterfaceId interfaceId) Add Node Event listener void addListener(NodeListener listener) EventTypes: NODE_ADDED, NODE_REMOVED, NODE_UPDATED, NODE_AVAILABILITY_CHANGED, INTERFACE_STATE_CHANGED Remove Node Event listenervoid removeListener(NodeListener listener) Get all Node Event listenersSet getListeners() Set Node friendly namevoid setName(Node Node, String name)

9 9 HostService API’sMethod Get all hostsIterator getHosts() Get hosts by segment ID (e.g. VLAN ID)Iterator getHosts(SegmentId segId) Get hosts by IP AddressSet getHosts(IpAddress ip) Get hosts by Connection PointSet getHosts(ConnectionPoint cp) Get hosts by Mac Address & Segment IDSet getHosts(MacAddress mac, SegmentId segId ) Get hosts by Node IDSet getHosts(NodeId node) Get hosts by filterIterator getHosts(HostFilter filter) Get host by IP Address and Segment IDgetHost(IpAddress ip, SegmentId segId) Add Host Event Listener void addListener(HostListener listener) EventTypes: HOST_ADDED, HOST_REMOVED, HOST_UPDATED, HOST_MOVED, Remove Host Event Listenervoid removeListener(HostListener listener) Get all Host Event ListenersSet getListeners() Network Service API’s - Hosts

10 10 LinkService API’sMethod Get all Infrastructure linksIterator getLinks() Get all links associated with the specified nodeSet getLinks(NodeId node) Get all links between two specified nodesSet getLinks(NodeId nodeA, NodeId nodeB) Get all links from specified nodeSet getLinksFrom(NodeId node) Get all links to specified nodeSet getLinksTo(NodeId node) Get all links containing the specified connection pointSet getLinks(ConnectionPoint cp) Get all links from the specified connection pointSet getLinksFrom(ConnectionPoint src) Get all links to the specified connection pointSet getLinksTo(ConnectionPoint dst) Add Link Event listener void addListener(LinkListener listener) EventTypes: LINK_ADDED, LINK_REMOVED, LINK_UPDATED Remove Link Event listenervoid removeListener(LinkListener listener) Get all Link Event listenersSet getListeners() Network Service API’s - Links

11 11 Topology Service API’s Method Get current topologyTopology getTopology() Determines whether the supplied connection point is part of the infrastructure (not a host port) boolean isInfrastructure(ConnectionPoint point) Determines whether the supplied connection point can be used for traffic broadcast boolean isBroadcastAllowed(ConnectionPoint point) Get all clusters in current topologySet getClusters() Get the cluster containing the specified nodeTopologyCluster getCluster(NodeId nodeId) Add Topology listener void addListener(TopologyListener listener) EventTypes: TOPOLOGY_CHANGED, CLUSTER_ADDED, CLUSTER_REMOVED Remove Topology listenervoid removeListener(TopologyListener listener) Get all Topology listenersSet getListeners() Network Service API’s – Topology

12 12 Path Service API’s Method Paves the specified path, for the traffic matching the supplied selector void pavePath(Path path, TrafficSelector selector, TrafficTreatment treatment) Parameters: path - path to be provisioned selector - selector identifying traffic to which the steering along the given path should be applied treatment - policy for treatment of traffic Validates whether a path between two nodes is viableboolean isPathViable(NodeId src, NodeId dst) Obtain a shortest path between two nodes using hop count as link weight Path getPath(NodeId src, NodeId dst) Obtain a shortest path between two nodes using supplied link weight Path getPath(NodeId src, NodeId dst, LinkWeight weight) Network Service API’s - Path

13  Simple Start  Just write APIs with methods that use MD-SAL directly Design Overview & Options 13  Optimize for Performance  Use Hash Maps instead of Tree Data Store  Create Hash Maps to index into Tree Data Store  Store Instance ID’s as keys  Store Object references as keys

14  Thanks! Q&A’s 14

15 ODL MD-SAL Analysis 15 Pros Model provides clear separation between operational and desired state Built-in model is extensible via new yang definition, which can augment existing entities and add new ones Framework provides for model-based code generation (to any language via language-bindings) and built-in REST-to-NETCONF access Provides a framework for pub/sub and RPC delegation when model data changes Cons Complexity of architecture and lack of documentation and communication on design and usage Lacks abstractions and requires consumers to explicitly interact with the model; there is no A in SAL Lacks information hiding; all APIs are exposed externally Tight coupling of model definition to Yang presents barrier to entry Suffers from issues with memory efficiency & performance Hard to use due to a number of factors: lack of abstraction, need for direct traversal to model entities

16 Flare vs. ODL Net Services Feature Comparison FeatureFlare BanthaODL Helium OpenFlow-Driven Node DiscoveryYY Manual Node DiscoveryYN ARP-Based Host TrackingYY DHCP-Based Host TrackingYN Flow Table InitializationYN Flow Table ReconciliationNY Default Flow Rule RegistrationYN First-Hop End-to-End L2 Path PavingYN L3 Path PavingYN Multiple Topologies?Y Client-Safe Link DiscoveryYN Rich Model Access API’sYN Multiple Path ComputationYN Configurable Link Discovery and Host Learning YN Hybrid Mode AwarenessYN

Download ppt "Simplified Network Service Interfaces Sept 29 2014"

Similar presentations

Ads by Google