jmsBean.setTopicPrefix("topicPrefix");
return jmsBean;
}
private static WorkflowJob createDummyWorkflow(int idx) {
JsonWorkflowJob workflow = new JsonWorkflowJob();
workflow.setId(JOB_ID + idx + JOB_ID_END);
workflow.setAppPath("hdfs://blah/blah/" + idx + "-blah");
workflow.setStatus((idx % 2) == 0 ? WorkflowJob.Status.RUNNING : WorkflowJob.Status.SUCCEEDED);
workflow.setRun(idx);
workflow.setCreatedTime(new Date());
workflow.setStartTime(new Date());
workflow.setEndTime((idx % 2) == 0 ? null : (new Date()));
workflow.setConf(CONFIGURATION);
workflow.setAppName("workflow-" + idx);
workflow.setGroup(GROUP);
workflow.setUser(USER);
List<JsonWorkflowAction> actions = new ArrayList<JsonWorkflowAction>();
for (int i = 0; i < idx; i++) {
actions.add(createDummyAction(i));
}
workflow.setActions(actions);
return workflow;
}