List of usage examples for com.amazonaws.services.simpleworkflow.model DecisionTask getEvents
public java.util.List<HistoryEvent> getEvents()
A paginated list of history events of the workflow execution.
From source file:aws.example.helloswf.WorkflowWorker.java
License:Apache License
public static void main(String[] args) { PollForDecisionTaskRequest task_request = new PollForDecisionTaskRequest().withDomain(HelloTypes.DOMAIN) .withTaskList(new TaskList().withName(HelloTypes.TASKLIST)); while (true) { System.out.println("Polling for a decision task from the tasklist '" + HelloTypes.TASKLIST + "' in the domain '" + HelloTypes.DOMAIN + "'."); DecisionTask task = swf.pollForDecisionTask(task_request); String taskToken = task.getTaskToken(); if (taskToken != null) { try { executeDecisionTask(taskToken, task.getEvents()); } catch (Throwable th) { th.printStackTrace();//from w w w .ja v a 2 s .c om } } } }