def __init__(self, name, host='127.0.0.1', port=27017):
        self.name = name
        self.host = host
        self.port = port
def json_usage(root):
    root = os.path.abspath(root)
    result = [['Path', 'Parent', 'Usage']]
    result.extend(entry for entry in usage_iter(root))
    return json.dumps(result)