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
Modifier and TypeMethodDescriptionaddConfiguration
(String config, Object value) Add in a single config.addConfigurations
(Map<String, Object> conf) add in several configs to the component.addResource
(String resourceName, Number resourceValue) Add generic resource for this component.addResources
(Map<String, Double> resources) Add generic resources for this component.return the current component configuration.setDebug
(boolean debug) Turn on/off debug for this component.setMaxSpoutPending
(Number val) Set the max spout pending config for this component.Set the max task parallelism for this component.setNumTasks
(Number val) Set the number of tasks for this component.Methods inherited from interface org.apache.storm.topology.ResourceDeclarer
addSharedMemory, setCPULoad, setMemoryLoad, setMemoryLoad
-
Method Details
-
addConfigurations
add in several configs to the component.- Parameters:
conf
- the configs to add- Returns:
- this for chaining.
-
getComponentConfiguration
return the current component configuration.- Returns:
- the current configuration.
-
addConfiguration
Add in a single config.- Parameters:
config
- the key for the configvalue
- the value of the config- Returns:
- this for chaining.
-
setDebug
Turn on/off debug for this component.- Parameters:
debug
- true for debug on false for debug off- Returns:
- this for chaining
-
setMaxTaskParallelism
Set the max task parallelism for this component.- Parameters:
val
- the maximum parallelism- Returns:
- this for chaining
-
setMaxSpoutPending
Set the max spout pending config for this component.- Parameters:
val
- the value of max spout pending.- Returns:
- this for chaining
-
setNumTasks
Set the number of tasks for this component.- Parameters:
val
- the number of tasks- Returns:
- this for chaining.
-
addResources
Add generic resources for this component. -
addResource
Add generic resource for this component.
-