← Back to packages

Package sentry_protos.taskbroker.v1

Service ConsumerService

Message RetryState

Message TaskActivation

Message GetTaskRequest

Message GetTaskResponse

Message FetchNextTask

Message SetTaskStatusRequest

Message SetTaskStatusResponse

Enum OnAttemptsExceeded

Enum TaskActivationStatus

Services

service ConsumerService sentry_protos/taskbroker/v1/taskbroker.proto

//////////////////////////
RPC messages and services
//////////////////////////

Messages

message RetryState sentry_protos/taskbroker/v1/taskbroker.proto

Field Type Description
1 attempts uint32

Current attempt number

2 max_attempts uint32

After this number of attempts, the task is either discarded or deadlettered.

3 on_attempts_exceeded sentry_protos.taskbroker.v1.OnAttemptsExceeded

The action to take after the max_attempts is exceeded.

4 at_most_once optional bool

Whether a task should be executed at most once.

message TaskActivation sentry_protos/taskbroker/v1/taskbroker.proto

Task message that is stored in Kafka and shared over RPC.

Field Type Description
1 id string

A GUID for the task. Used to update tasks

2 namespace string

The task namespace

3 taskname string

The name of the task. This name is resolved within the worker

4 parameters string

An opaque parameter collection. Could be JSON or protobuf encoded

5 headers map<string, string>

A map of headers for the task.

6 received_at google.protobuf.Timestamp

The timestamp a task was stored in Kafka

7 retry_state sentry_protos.taskbroker.v1.RetryState

Retry state

8 processing_deadline_duration uint64

The duration in seconds that a worker has to complete task execution.
When an activation is moved from pending -> processing a result is expected
in this many seconds.

9 expires optional uint64

The duration in seconds that a task has to start execution.
After received_at + expires has passed an activation is expired and will not be executed.

message GetTaskRequest sentry_protos/taskbroker/v1/taskbroker.proto

Field Type Description
1 namespace optional string

message GetTaskResponse sentry_protos/taskbroker/v1/taskbroker.proto

Field Type Description
1 task optional sentry_protos.taskbroker.v1.TaskActivation

If there are no tasks available, this will be empty

message FetchNextTask sentry_protos/taskbroker/v1/taskbroker.proto

Field Type Description
1 namespace optional string

message SetTaskStatusRequest sentry_protos/taskbroker/v1/taskbroker.proto

Field Type Description
1 id string
2 status sentry_protos.taskbroker.v1.TaskActivationStatus
3 fetch_next_task optional sentry_protos.taskbroker.v1.FetchNextTask

If fetch_next is provided, receive a new task in the response

message SetTaskStatusResponse sentry_protos/taskbroker/v1/taskbroker.proto

Field Type Description
1 task optional sentry_protos.taskbroker.v1.TaskActivation

The next task the worker should execute. Requires fetch_next to be set on the request.

Enums

enum OnAttemptsExceeded sentry_protos/taskbroker/v1/taskbroker.proto

Name Number Description
ON_ATTEMPTS_EXCEEDED_UNSPECIFIED 0
ON_ATTEMPTS_EXCEEDED_DISCARD 1
ON_ATTEMPTS_EXCEEDED_DEADLETTER 2

enum TaskActivationStatus sentry_protos/taskbroker/v1/taskbroker.proto

Name Number Description
TASK_ACTIVATION_STATUS_UNSPECIFIED 0
TASK_ACTIVATION_STATUS_PENDING 1
TASK_ACTIVATION_STATUS_PROCESSING 2
TASK_ACTIVATION_STATUS_FAILURE 3
TASK_ACTIVATION_STATUS_RETRY 4
TASK_ACTIVATION_STATUS_COMPLETE 5