/topology

Kytos Main Topology Network Application (NApp)

Primary LanguagePythonMIT LicenseMIT

Overview

License Build status Code coverage Code-quality score

Attention!

THIS NAPP IS STILL EXPERIMENTAL AND IT'S EVENTS, METHODS AND STRUCTURES MAY CHANGE A LOT ON THE NEXT FEW DAYS/WEEKS, USE IT AT YOUR OWN DISCERNEMENT

This NApp is responsible for tracking the network topology and supplying network topology information to any NApp that requires it.

This NApp intends to be protocol agnostic. Therefore, if you want to provide network topology data from any network protocol, check the listened events section and generate them from your NApp.

Installing

All of the Kytos Network Applications are located in the NApps online repository. To install this NApp, run:

$ kytos napps install kytos/topology

Requirements

  • kytos/of_core
  • kytos/of_lldp
  • kytos/storehouse

Configuring

You have few options to configure the behaviour of this NApp in the settings.py file. Please take a look in this file.

You can customize circuits in the topology using a JSON configuration file. See etc/circuits.json.sample for an example.

Circuits can have a name, a list of hops and as many numeric custom properties as the user wants.

We are working to deliver methods and resources to extend the custom properties in the future.

Events

Listened

.*.switch.new

Event reporting that a new switch was created/added on the network.

Content
{
  'switch': <Switch object>  # kytos.core.switch.Switch class
}

.*.switch.port.created

Event reporting that a port was created/added in the switch/datapath.

Content
{
  'switch': <switch id>,
  'port': <port number>,
  'port_description': {<description of the port>}  # port description dict
}

.*.switch.port.modified

Event reporting that a port was modified in the datapath.

Content
{
  'switch': <switch id>,
  'port': <port number>,
  'port_description': {<description of the port>}  # port description dict
}

.*.switch.port.deleted

Event reporting that a port was deleted from the datapath.

Content
{
  'switch': <switch id>,
  'port': <port number>,
  'port_description': {<description of the port>}  # port description dict
}

.*.interface.is.nni

Event reporting that two interfaces were identified as NNI interfaces.

Content
{
  'interface_a': {
     'switch': <switch id>,
     'port': <port number>
  },
  'interface_b': {
     'switch': <switch id>,
     'port': <port number>
  }
}

.*.reachable.mac

Event reporting that a mac address is reachable from a specific switch/port.

Content
{
    'switch': <switch id>,
    'port': <port number>,
    'reachable_mac': <mac address>
}

Generated

kytos/topology.updated

Event reporting that the topology was updated. It contains the most updated topology.

Content
{
  'topology': <Topology object>
}

Rest API

You can find a list of the available endpoints and example input/output in the 'REST API' tab in this NApp's webpage in the Kytos NApps Server.