Skip to main content

Interface: IPollWorkflowTaskQueueResponse

workflowservice.v1.IPollWorkflowTaskQueueResponse

Properties of a PollWorkflowTaskQueueResponse.

Hierarchy

Properties

attempt

Optional attempt: null | number

Starting at 1, the number of attempts to complete this task by any worker.

Inherited from

$Properties.attempt


backlogCountHint

Optional backlogCountHint: null | Long

A hint that there are more tasks already present in this task queue partition. Can be used to prioritize draining a sticky queue.

Specifically, the returned number is the number of tasks remaining in the in-memory buffer for this partition, which is currently capped at 1000. Because sticky queues only have one partition, this number is more useful when draining them. Normal queues, typically having more than one partition, will return a number representing only some portion of the overall backlog. Subsequent RPCs may not hit the same partition as this call.

Inherited from

$Properties.backlogCountHint


history

Optional history: null | $Properties

The history for this workflow, which will either be complete or partial. Partial histories are sent to workers who have signaled that they are using a sticky queue when completing a workflow task.

Inherited from

$Properties.history


messages

Optional messages: null | $Properties[]

Protocol messages piggybacking on a WFT as a transport

Inherited from

$Properties.messages


nextPageToken

Optional nextPageToken: null | Uint8Array

Will be set if there are more history events than were included in this response. Such events should be fetched via GetWorkflowExecutionHistory.

Inherited from

$Properties.nextPageToken


pollerGroupId

Optional pollerGroupId: null | string

This poller group ID identifies the owner of the workflow task awaiting for query response. Corresponding RespondQueryTaskCompleted should pass this value for proper routing.

Inherited from

$Properties.pollerGroupId


pollerGroupInfos

Optional pollerGroupInfos: null | $Properties[]

Deprecated. Use poller_groups_info instead, which carries a version so the client can ignore stale updates. The weighted list of poller groups IDs that client should use for future polls to this task queue. Client is expected to:

  1. Maintain minimum number of pollers no less than the number of groups.
  2. Try to assign the next poll to a group without any pending polls,
  3. If every group has some pending polls, assign the next poll to a group randomly according to the weights.

Inherited from

$Properties.pollerGroupInfos


pollerGroupsInfo

Optional pollerGroupsInfo: null | $Properties

The weighted, versioned list of poller groups IDs that client should use for future polls to this task queue. Client should ignore this if it has already applied a snapshot with a version greater than or equal to poller_groups_info.version. Client is expected to:

  1. Maintain minimum number of pollers no less than the number of groups.
  2. Try to assign the next poll to a group without any pending polls,
  3. If every group has some pending polls, assign the next poll to a group randomly according to the weights.

Inherited from

$Properties.pollerGroupsInfo


pollerScalingDecision

Optional pollerScalingDecision: null | $Properties

Server-advised information the SDK may use to adjust its poller count.

Inherited from

$Properties.pollerScalingDecision


previousStartedEventId

Optional previousStartedEventId: null | Long

The last workflow task started event which was processed by some worker for this execution. Will be zero if no task has ever started.

Inherited from

$Properties.previousStartedEventId


queries

Optional queries: null | { [k: string]: $Properties; }

Queries that should be executed after applying the history in this task. Responses should be attached to RespondWorkflowTaskCompletedRequest::query_results

Inherited from

$Properties.queries


query

Optional query: null | $Properties

Legacy queries appear in this field. The query must be responded to via RespondQueryTaskCompleted. If the workflow is already closed (queries are permitted on closed workflows) then the history field will be populated with the entire history. It may also be populated if this task originates on a non-sticky queue.

Inherited from

$Properties.query


scheduledTime

Optional scheduledTime: null | $Properties

When this task was scheduled by the server

Inherited from

$Properties.scheduledTime


startedEventId

Optional startedEventId: null | Long

The id of the most recent workflow task started event, which will have been generated as a result of this poll request being served. Will be zero if the task does not contain any events which would advance history (no new WFT started). Currently this can happen for queries.

Inherited from

$Properties.startedEventId


startedTime

Optional startedTime: null | $Properties

When the current workflow task started event was generated, meaning the current attempt.

Inherited from

$Properties.startedTime


taskToken

Optional taskToken: null | Uint8Array

A unique identifier for this task

Inherited from

$Properties.taskToken


workflowExecution

Optional workflowExecution: null | $Properties

PollWorkflowTaskQueueResponse workflowExecution

Inherited from

$Properties.workflowExecution


workflowExecutionTaskQueue

Optional workflowExecutionTaskQueue: null | $Properties

The task queue this task originated from, which will always be the original non-sticky name for the queue, even if this response came from polling a sticky queue.

Inherited from

$Properties.workflowExecutionTaskQueue


workflowType

Optional workflowType: null | $Properties

PollWorkflowTaskQueueResponse workflowType

Inherited from

$Properties.workflowType