List of usage examples for org.apache.hadoop.registry.client.api RegistryOperations init
void init(Configuration config);
From source file:org.apache.slider.providers.agent.TestAgentProviderService.java
License:Apache License
protected YarnRegistryViewForProviders createYarnRegistryViewForProviders(Configuration conf) throws IOException { conf.set(SliderXmlConfKeys.REGISTRY_PATH, SliderXmlConfKeys.DEFAULT_REGISTRY_PATH); RegistryOperations registryOperations = new MockRegistryOperations(); registryOperations.init(conf); YarnRegistryViewForProviders registryViewForProviders = new YarnRegistryViewForProviders(registryOperations, "hbase", SliderKeys.APP_TYPE, "hbase1", new MockApplicationAttemptId(new MockApplicationId(1), 1)); registryViewForProviders.registerSelf(new ServiceRecord(), true); return registryViewForProviders; }