Skip to content

Add activity cancels from nexus#1160

Open
Sushisource wants to merge 8 commits into
mainfrom
add-activity-cancels-from-nexus
Open

Add activity cancels from nexus#1160
Sushisource wants to merge 8 commits into
mainfrom
add-activity-cancels-from-nexus

Conversation

@Sushisource
Copy link
Copy Markdown
Member

@Sushisource Sushisource commented Mar 17, 2026

Creates a worker which polls on the appropriately-named worker commands nexus task queue, and handles and activity cancellations sent down it.

The worker is not started unless the server supports this capability.

Warning

Still waiting on server impl for integ test to pass

task_token: Vec<u8>,
commands: Vec<WorkerCommand>,
) -> PollNexusTaskQueueResponse {
let exec_req = ExecuteCommandsRequest { commands };
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please incorporate the following changes:

  1. Set task_kind to worker_commands. Add new task queue kind to send worker commands api#763
  2. Guard new code (creating nexus queue, polling, processing) with worker_commands capability: Add worker_commands namespace capability api#771

}
}
}
pub mod nexusservices {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the nexus worker send heartbeat? If it does, then I need to find a way to exclude this from the ListWorkers result.

Copy link
Copy Markdown
Member Author

@Sushisource Sushisource May 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

~Good question. It shouldn't, if it does I'll make sure it doesn't. ~

Changed my mind. We are already making sure it gets excluded from metrics (since we saw it show up and had that whole discussion re: Nexus usage), and being able to diagnose possible issues with it (getting overloaded, not enough slots, whatever) is useful. Also being dealt with here: temporalio/cli#1019

@Sushisource Sushisource force-pushed the add-activity-cancels-from-nexus branch from 05bb5c8 to 322f2a4 Compare May 11, 2026 21:26
@Sushisource Sushisource force-pushed the add-activity-cancels-from-nexus branch from 322f2a4 to 4f0e626 Compare May 11, 2026 22:08
@Sushisource Sushisource marked this pull request as ready for review May 11, 2026 22:08
@Sushisource Sushisource requested a review from a team as a code owner May 11, 2026 22:09
@Sushisource Sushisource force-pushed the add-activity-cancels-from-nexus branch from 4f0e626 to 8bc16e3 Compare May 11, 2026 22:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants