def load(name): """ Foreground load data via a single plugin """ if name in modules.keys(): modules[name].process() data = modules[name].load(str(name)) print json.dumps(data, indent=2)
def get(): data = {} # load each module's data from memcache for m in modules.keys(): data[m] = modules[m].load(m) # response with formatted json return _make_json_response(data)
def get(name): """ Inspect the data in memcache """ data = {} for m in modules.keys(): data[m] = modules[m].load(m) print json.dumps(data, indent=2)
def poll(): # force start of all plugins for m in modules.keys(): modules[m].delay() return _make_json_response({'OK': True})