projects
/
osm
/
openvim.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Move openvim version/date/db_version to ovim
[osm/openvim.git]
/
ovim.py
diff --git
a/ovim.py
b/ovim.py
index
15bde75
..
edd0b4c
100644
(file)
--- a/
ovim.py
+++ b/
ovim.py
@@
-28,6
+28,9
@@
Two thread will be launched, with normal and administrative permissions.
__author__ = "Alfonso Tierno, Leonardo Mirabal"
__date__ = "$06-Feb-2017 12:07:15$"
__author__ = "Alfonso Tierno, Leonardo Mirabal"
__date__ = "$06-Feb-2017 12:07:15$"
+__version__ = "0.5.8-r524"
+version_date = "March 2017"
+database_version = "0.15" #expected database schema version
import threading
import vim_db
import threading
import vim_db
@@
-109,6
+112,18
@@
class ovim():
self.config['db_host']) )
return db
self.config['db_host']) )
return db
+ @staticmethod
+ def get_version():
+ return __version__
+
+ @staticmethod
+ def get_version_date():
+ return version_date
+
+ @staticmethod
+ def get_database_version():
+ return database_version
+
@staticmethod
def _check_dhcp_data_integrity(network):
"""
@staticmethod
def _check_dhcp_data_integrity(network):
"""
@@
-939,7
+954,7
@@
class ovim():
r, c = ofc_t[switch_dpid].insert_task("update-net", net_id)
if r < 0:
r, c = ofc_t[switch_dpid].insert_task("update-net", net_id)
if r < 0:
- message = "Cannot insert a task for updating network '
$s', %s", net_id, c
+ message = "Cannot insert a task for updating network '
{}', {}".format(net_id, c)
self.logger.error(message)
raise ovimException(message, HTTP_Internal_Server_Error)
self.logger.error(message)
raise ovimException(message, HTTP_Internal_Server_Error)