Skip to content

Commit

Permalink
[networking.links] Added update_topology to CELERYBEAT_SCHEDULE #231
Browse files Browse the repository at this point in the history
  • Loading branch information
nemesifier committed May 30, 2015
1 parent 3cf8b89 commit 8264783
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions nodeshot/networking/links/settings.py 100755 → 100644
@@ -1,4 +1,5 @@
from django.conf import settings
from datetime import timedelta

DEFAULT_PARSERS = [
('netdiff.OlsrParser', 'OLSR (jsoninfo)'),
Expand All @@ -9,3 +10,12 @@
]

PARSERS = DEFAULT_PARSERS + getattr(settings, 'NODESHOT_NETDIFF_PARSERS', [])

TOPOLOGY_UPDATE_INTERVAL = getattr(settings, 'NODESHOT_TOPOLOGY_UPDATE_INTERVAL', 3)

settings.CELERYBEAT_SCHEDULE.update({
'update_topology': {
'task': 'nodeshot.networking.links.tasks.update_topology',
'schedule': timedelta(minutes=TOPOLOGY_UPDATE_INTERVAL),
}
})

0 comments on commit 8264783

Please sign in to comment.