Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
None
-
None
-
None
Description
The current implementation of WorkerTopologyContext in WorkerState will always lead to empty userResources as no interface exposes a way to allow user to set them.
private Map<String, Object> makeUserResources() { /* TODO: need to invoke a hook provided by the topology, giving it a chance to create user resources. * this would be part of the initialization hook * need to separate workertopologycontext into WorkerContext and WorkerUserContext. * actually just do it via interfaces. just need to make sure to hide setResource from tasks */ return new HashMap<>(); }
The intention will be to expose the relevant methods under a separate class which can then allow users to set the resources from WorkerHooks while only providing get access from Tasks (i.e. via TopologyContext)
Attachments
Issue Links
- fixes
-
STORM-172 Add hooks for creating shared resources among tasks
- Closed
- links to