Exemple #1
0
 /**
  * simple test TaskUpdatedEvent and TaskUpdated
  *
  * @throws Exception
  */
 @Test(timeout = 10000)
 public void testTaskUpdated() throws Exception {
   JobID jid = new JobID("001", 1);
   TaskID tid = new TaskID(jid, TaskType.REDUCE, 2);
   TaskUpdatedEvent test = new TaskUpdatedEvent(tid, 1234L);
   assertEquals(test.getTaskId().toString(), tid.toString());
   assertEquals(test.getFinishTime(), 1234L);
 }
 public void apply(TaskUpdatedEvent event) {
   log.info("Calling TaskAggregate.APPLY for TaskUpdatedEvent : {}", event);
   this.task.setTaskDetails(event.getTaskDetails());
   this.task.setUpdate(event.getUpdate());
 }