use of com.yahoo.container.core.ChainsConfig.Components in project vespa by vespa-engine.
the class ChainsModelBuilderTest method chainsModel.
private ChainsModel chainsModel() {
ChainsConfig.Builder builder = new ChainsConfig.Builder().components(new Components.Builder().id("componentA")).components(new Components.Builder().id("componentB")).chains(new Chains.Builder().id("chain1").components("componentA").components("componentB")).chains(new Chains.Builder().id("inheritsChain1").inherits("chain1").excludes("componentA"));
ChainsConfig config = new ChainsConfig(builder);
ChainsModel model = ChainsModelBuilder.buildFromConfig(config);
model.validate();
return model;
}
use of com.yahoo.container.core.ChainsConfig.Components in project vespa by vespa-engine.
the class DomSearchChainsBuilderTest method checkInnerSearcherIdIsNestedInSearchChainId.
private void checkInnerSearcherIdIsNestedInSearchChainId(ChainsConfig config, String partOfSearcherName, String searchChainName) {
Components searcher = getSearcherConfig(config.components(), partOfSearcherName);
ComponentId searcherId = ComponentId.fromString(searcher.id());
assertThat(searcherId.getNamespace(), is(getSearchChain(searchChainName).getComponentId()));
Chains searchChain = getSearchChainConfig(config.chains(), searchChainName);
assertThat(ComponentId.fromString(searchChain.components(0)), is(searcherId));
}
Aggregations