PipelineAssemblerImpl extends PipelineAssembler implements ApplicationContextAware { @Override public ActionConfig getActionConfig(ConfiguredAction configuredAction){ HashMap<String, ActionConfig> map = new HashMap<String, ActionConfig>(); String classId = configuredAction.getClassId(); ClassInfoModel classInfoModel = actionClassService.getClassInfoModel(classId); Class clazz = classInfoModel.getClazz(); Map<String, String> parameters = configuredAction.getParameters(); M2AActionFactory factory = new M2AActionFactory(clazz, parameters, beanFactory); ActionConfig actionConfig = new ActionConfig(configuredAction.getActionId(), factory, configuredAction.getNmbOfWorkers()); map.put(configuredAction.getActionId(), actionConfig); configuredActionToActionConfig(configuredAction, map); return actionConfig; }  void setActionClassService(ActionClassInfoService actionClassService); @Override JobModel getJobConfigForJob(final int id); @Override ActionConfig getActionConfig(ConfiguredAction configuredAction); @Override ConfiguredAction getConfiguredAction(final JobModel jobModel); @Override void setApplicationContext(ApplicationContext applicationContext); static final String SOURCE_ID; static final String SOURCE_CMIS_ID; static final String MOVE_BEFORE_ID; static final String MOVE_AFTER_ID; @Deprecated
    static final String MOVE_WITH_COUNTER; static final String MOVE_NOT_LOADED_ID; static final String FILTER_ID; static final String METADATA_ACTION_ID; static final String TRANSFORM_ACTION_ID; static final String MIME_TYPE_ID; static final String UPLOAD_ID; static final String DELETE_ID; static final String EXISTENCE_CHECK_ID; static final String LIST_ID; static final String COMMAND_BEFORE_ID; static final String COMMAND_AFTER_ID; static final String DEFAULT_RECEIVER; static final String UPLOAD_RECEIVER; static final String REPORTER; static final String END_ACTION; static final String START; static final String UPLOADED_FILE_HANDLER; static final String PUT_CONTENT; static final String BATCH_ACTION; static final String REPORT_SAVER; static final String PINNED_DISPATCHER; static final String ALFRESCO_ACL_ACTION; static final String VALIDATE_DESTINATION; static final String RECURSIVE_CMIS; static final String CMIS_QUERY; static final String SEPARATOR; }
@Test public void getActionConfigTest(){ PipelineAssemblerImpl pipeline = new PipelineAssemblerImpl(); pipeline.setApplicationContext(applicationContext); pipeline.setActionClassService(actionClassService); ConfiguredAction start = mockConfiguredAction(); ActionConfig actionConfig = pipeline.getActionConfig(start); assertEquals(actionConfig.getReceivers().entrySet().size(), 1); ActionConfig validateAction = actionConfig.getReceivers().get(PipelineAssemblerImpl.DEFAULT_RECEIVER); assertNotNull(validateAction); assertEquals(PipelineAssemblerImpl.VALIDATE_DESTINATION,validateAction.getId()); assertEquals(validateAction.getReceivers().entrySet().size(), 2); ActionConfig sourceAction = validateAction.getReceivers().get(PipelineAssemblerImpl.DEFAULT_RECEIVER); assertNotNull(sourceAction); assertEquals(PipelineAssemblerImpl.SOURCE_CMIS_ID,sourceAction.getId()); assertEquals(sourceAction.getReceivers().entrySet().size(), 2); ActionConfig cmisRecursive = sourceAction.getReceivers().get(PipelineAssemblerImpl.DEFAULT_RECEIVER); assertNotNull(cmisRecursive); assertEquals(PipelineAssemblerImpl.RECURSIVE_CMIS,cmisRecursive.getId()); assertEquals(cmisRecursive.getReceivers().entrySet().size(), 2); ActionConfig cmisQuery = cmisRecursive.getReceivers().get(PipelineAssemblerImpl.DEFAULT_RECEIVER); assertNotNull(cmisQuery); assertEquals(PipelineAssemblerImpl.CMIS_QUERY,cmisQuery.getId()); assertEquals(cmisQuery.getReceivers().entrySet().size(), 3); }