Search in sources :

Example 1 with DecisionTaskTimedOutEventAttributes

use of com.uber.cadence.DecisionTaskTimedOutEventAttributes in project cadence-client by uber-java.

the class StateMachines method timeoutDecisionTask.

private static void timeoutDecisionTask(RequestContext ctx, DecisionTaskData data, Object ignored, long notUsed) {
    DecisionTaskTimedOutEventAttributes a = new DecisionTaskTimedOutEventAttributes().setStartedEventId(data.previousStartedEventId).setTimeoutType(TimeoutType.START_TO_CLOSE).setScheduledEventId(data.scheduledEventId);
    HistoryEvent event = new HistoryEvent().setEventType(EventType.DecisionTaskTimedOut).setDecisionTaskTimedOutEventAttributes(a);
    ctx.addEvent(event);
}
Also used : DecisionTaskTimedOutEventAttributes(com.uber.cadence.DecisionTaskTimedOutEventAttributes) HistoryEvent(com.uber.cadence.HistoryEvent)

Aggregations

DecisionTaskTimedOutEventAttributes (com.uber.cadence.DecisionTaskTimedOutEventAttributes)1 HistoryEvent (com.uber.cadence.HistoryEvent)1