def get_inventory(storage_type, inventory_base_uri, nodes_uri, classes_uri, class_mappings): nodes_uri, classes_uri = path_mangler(inventory_base_uri, nodes_uri, classes_uri) storage = get_storage(storage_type, nodes_uri, classes_uri, class_mappings) return storage.inventory()
def get_nodeinfo(storage_type, inventory_base_uri, nodes_uri, classes_uri, nodename, class_mappings): nodes_uri, classes_uri = path_mangler(inventory_base_uri, nodes_uri, classes_uri) storage = get_storage(storage_type, nodes_uri, classes_uri, class_mappings) # TODO: template interpolation return storage.nodeinfo(nodename)
def get_inventory(storage_type, inventory_base_uri, nodes_uri, classes_uri): nodes_uri, classes_uri = path_mangler(inventory_base_uri, nodes_uri, classes_uri) storage = get_storage(storage_type, nodes_uri, classes_uri) return storage.inventory()
def get_nodeinfo(storage_type, inventory_base_uri, nodes_uri, classes_uri, nodename): nodes_uri, classes_uri = path_mangler(inventory_base_uri, nodes_uri, classes_uri) storage = get_storage(storage_type, nodes_uri, classes_uri) # TODO: template interpolation return storage.nodeinfo(nodename)