private void addParametersForIncludedSources(Set<Source> sources, Query query) {
        for (Source source : sources) {
            if (!source.parameters().isEmpty() && query.getModel().getSources().contains(source.getName()))
                addParameters(source,query);
        }
    }
Sets query.getModel().getSources() to the right value and add source parameters specified in templates
container-search/src/main/java/com/yahoo/search/pagetemplates/PageTemplateSearcher.java