Beispiel #1
0
def get_metrics_queue(config, _=None):
    q = Queue('%s/dashboard.q' % (config.temboard['home']),
              max_length=(config.plugins['dashboard']['history_length'] + 1),
              overflow_mode='slide')
    dm = DashboardMetrics()
    msg = q.get_last_message()
    msg['notifications'] = dm.get_notifications(config)
    return msg
Beispiel #2
0
def get_metrics_queue(config, _=None):
    q = Queue('%s/dashboard.q' % (config.temboard['home']))
    dm = DashboardMetrics()
    msg = q.get_last_message()
    msg['notifications'] = dm.get_notifications(config)
    return msg
def get_metrics_queue(config):
    q = Queue(os.path.join(config.temboard.home, 'dashboard.q'))
    dm = DashboardMetrics()
    msg = q.get_last_message()
    msg['notifications'] = dm.get_notifications(config)
    return msg