kytos / topology

Kytos Main Topology Network Application (NApp)
https://napps.kytos.io/kytos/topology
MIT License
0 stars 19 forks source link

Restore of administrative state automatic on kytos bootstrap #124

Closed cmagnobarbosa closed 3 years ago

cmagnobarbosa commented 4 years ago

Today, after an unexpected quit of kytos, the user needs to execute a command through the REST Endpoint GET \ restore to recover and restore the administrative state saved in the storehouse. But, this recovery is expected to be automatic.

Pseudocode behavior expected:

kytos_running:
  # store administrative changes (switches, interfaces, lldp and links)
  any_change_detected:
    store_changes()

In kytos bootstrap

kytos_bootstrap:
  if has_changes_stored:
    _restore_changes()

Note: To use this change, it is recommended to clear the kytos.topology.status namespace in storehouse.

Related: kytos/kytos#1127