Package io.temporal.internal.worker
Interface ActivityTaskHandler
-
- All Known Implementing Classes:
ActivityTaskHandlerImpl
public interface ActivityTaskHandler
Interface of an activity task handler.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
ActivityTaskHandler.Result
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ActivityTaskHandler.Result
handle(ActivityTask activityTask, com.uber.m3.tally.Scope metricsScope, boolean isLocalActivity)
The implementation should be called when a polling activity worker receives a new activity task.boolean
isAnyTypeSupported()
True if this handler handles at least one activity type.boolean
isTypeSupported(java.lang.String activityType)
-
-
-
Method Detail
-
handle
ActivityTaskHandler.Result handle(ActivityTask activityTask, com.uber.m3.tally.Scope metricsScope, boolean isLocalActivity)
The implementation should be called when a polling activity worker receives a new activity task. This method shouldn't throw any Throwables unless there is a need to not reply to the task.- Parameters:
activityTask
- activity task which is response to PollActivityTaskQueue call.- Returns:
- One of the possible activity task replies.
-
isAnyTypeSupported
boolean isAnyTypeSupported()
True if this handler handles at least one activity type.
-
isTypeSupported
boolean isTypeSupported(java.lang.String activityType)
- Parameters:
activityType
- activity type name- Returns:
- true if an activity implementation with
activityType
name is registered or a dynamic activity implementation is registered.
-
-