private CompiledQueryProfileRegistry readQueryProfilesFromApplicationPackage(Path path) {
        String queryProfilePath = path + "/search/query-profiles";
        QueryProfileXMLReader queryProfileXMLReader = new QueryProfileXMLReader();

        File f = new File(queryProfilePath);
        if(f.exists() && f.isDirectory()) {
            return queryProfileXMLReader.read(queryProfilePath).compile();
        }
        return CompiledQueryProfileRegistry.empty;
    }
Factory method to create an Application from an application package.
This method allows deploying OSGi bundles(contained in the components subdirectory).
All the OSGi bundles will share the same class loader.

@param file the reference to the application package to use
@return a new JDisc instance
application/src/main/java/com/yahoo/application/Application.java