List of usage examples for org.apache.hadoop.registry.client.binding RegistryUtils componentPath
public static String componentPath(String user, String serviceClass, String serviceName, String componentName)
From source file:com.alibaba.jstorm.yarn.registry.YarnRegistryViewForProviders.java
License:Apache License
/** * Add a component /*from w w w . ja va 2 s.c o m*/ * @param serviceClass service class to use under ~user * @param componentName component name * @param record record to put * @throws IOException */ public void putComponent(String serviceClass, String serviceName, String componentName, ServiceRecord record) throws IOException { String path = RegistryUtils.componentPath(user, serviceClass, serviceName, componentName); registryOperations.mknode(RegistryPathUtils.parentOf(path), true); registryOperations.bind(path, record, BindFlags.OVERWRITE); }
From source file:com.alibaba.jstorm.yarn.registry.YarnRegistryViewForProviders.java
License:Apache License
/** * Delete a component//from ww w . ja v a 2 s . c o m * @param componentName component name * @throws IOException */ public void deleteComponent(String componentName) throws IOException { String path = RegistryUtils.componentPath(user, jstormServiceClass, instanceName, componentName); registryOperations.delete(path, false); }
From source file:org.apache.slider.server.services.yarnregistry.YarnRegistryViewForProviders.java
License:Apache License
/** * Delete a component/* www .jav a 2 s. c o m*/ * @param componentName component name * @throws IOException */ public void deleteComponent(String componentName) throws IOException { String path = RegistryUtils.componentPath(user, sliderServiceClass, instanceName, componentName); registryOperations.delete(path, false); }