Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 49 additions & 0 deletions temporal/api/worker/v1/worker_nexus_service_commands.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
syntax = "proto3";

package temporal.api.worker.v1;

option go_package = "go.temporal.io/api/worker/v1;worker";
option java_package = "io.temporal.api.worker.v1";
option java_multiple_files = true;
option java_outer_classname = "WorkerNexusServiceCommandsProto";
option ruby_package = "Temporalio::Api::Worker::V1";
option csharp_namespace = "Temporalio.Api.Worker.V1";

// (--
/////////////////////////////////////////////////////////////////////
// This file contains:
// - Conventions between server and worker.
// - Definitions for commands and payloads for server-worker communication via Nexus
//
// COMMUNICATION PROTOCOL:
// - Transport: Nexus tasks on task queue
// - Server identifier: "sys-worker-service"
// - Task queue: /temporal-sys/worker-commands/{namespace}/{worker_grouping_key}
//
// WORKER COMMANDS CONVENTIONS:
//
// - Worker commands are used to manage worker configurations, operations, etc.
// - Command names should match names defined in the server API.
// - Command names are provided in StartOperationRequest.Operation field.
//
// PAYLOAD CONVENTIONS:
//
// - In/out payloads namings follow the same convention as the regular API:
// - CommandNameRequest (input payload)
// - CommandNameResponse (output payload).
// - Empty payload if response is not needed/not expected
//
// --)

// Request payload for the "cancel-activities" Nexus operation.
message CancelActivitiesRequestPayload {
// Task tokens identifying the activities to cancel.
// Each token corresponds to a specific activity task that the worker received.
repeated bytes task_tokens = 1;
}

// Response payload for the "cancel-activities" Nexus operation.
message CancelActivitiesResponsePayload {
// Empty for now. Can be extended to include cancellation status per activity.
}

Loading