Package org.apache.storm.topology
Interface ComponentConfigurationDeclarer<T extends ComponentConfigurationDeclarer>
-
- All Superinterfaces:
ResourceDeclarer<T>
- All Known Subinterfaces:
BoltDeclarer,LinearDRPCInputDeclarer,SpoutDeclarer
- All Known Implementing Classes:
BaseConfigurationDeclarer,TopologyBuilder.BoltGetter,TopologyBuilder.ConfigGetter,TopologyBuilder.SpoutGetter
public interface ComponentConfigurationDeclarer<T extends ComponentConfigurationDeclarer> extends ResourceDeclarer<T>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TaddConfiguration(String config, Object value)Add in a single config.TaddConfigurations(Map<String,Object> conf)add in several configs to the component.TaddResource(String resourceName, Number resourceValue)Add generic resource for this component.TaddResources(Map<String,Double> resources)Add generic resources for this component.Map<String,Object>getComponentConfiguration()return the current component configuration.TsetDebug(boolean debug)Turn on/off debug for this component.TsetMaxSpoutPending(Number val)Set the max spout pending config for this component.TsetMaxTaskParallelism(Number val)Set the max task parallelism for this component.TsetNumTasks(Number val)Set the number of tasks for this component.-
Methods inherited from interface org.apache.storm.topology.ResourceDeclarer
addSharedMemory, setCPULoad, setMemoryLoad, setMemoryLoad
-
-
-
-
Method Detail
-
addConfigurations
T addConfigurations(Map<String,Object> conf)
add in several configs to the component.- Parameters:
conf- the configs to add- Returns:
- this for chaining.
-
getComponentConfiguration
Map<String,Object> getComponentConfiguration()
return the current component configuration.- Returns:
- the current configuration.
-
addConfiguration
T addConfiguration(String config, Object value)
Add in a single config.- Parameters:
config- the key for the configvalue- the value of the config- Returns:
- this for chaining.
-
setDebug
T setDebug(boolean debug)
Turn on/off debug for this component.- Parameters:
debug- true for debug on false for debug off- Returns:
- this for chaining
-
setMaxTaskParallelism
T setMaxTaskParallelism(Number val)
Set the max task parallelism for this component.- Parameters:
val- the maximum parallelism- Returns:
- this for chaining
-
setMaxSpoutPending
T setMaxSpoutPending(Number val)
Set the max spout pending config for this component.- Parameters:
val- the value of max spout pending.- Returns:
- this for chaining
-
setNumTasks
T setNumTasks(Number val)
Set the number of tasks for this component.- Parameters:
val- the number of tasks- Returns:
- this for chaining.
-
addResources
T addResources(Map<String,Double> resources)
Add generic resources for this component.
-
-