use of com.hortonworks.streamline.streams.layout.component.impl.splitjoin.StageProcessor in project streamline by hortonworks.
the class TopologyComponentFactory method stageProcessorProvider.
private Map.Entry<String, Provider<StreamlineProcessor>> stageProcessorProvider() {
Provider<StreamlineProcessor> provider = new Provider<StreamlineProcessor>() {
@Override
public StreamlineProcessor create(TopologyComponent component) {
Object stageConfig = component.getConfig().getAny(StageProcessor.CONFIG_KEY_STAGE);
ObjectMapper objectMapper = new ObjectMapper();
StageAction stageAction = objectMapper.convertValue(stageConfig, StageAction.class);
StageProcessor stageProcessor = new StageProcessor();
stageProcessor.setStageAction(stageAction);
return stageProcessor;
}
};
return new SimpleImmutableEntry<>(STAGE, provider);
}
Aggregations