Skip to content

Exclude system workers from ListWorkers by default#10132

Merged
rkannan82 merged 16 commits intomainfrom
kannan/list-workers-exclude-system
May 2, 2026
Merged

Exclude system workers from ListWorkers by default#10132
rkannan82 merged 16 commits intomainfrom
kannan/list-workers-exclude-system

Conversation

@rkannan82
Copy link
Copy Markdown
Contributor

@rkannan82 rkannan82 commented Apr 30, 2026

What

Exclude internal system workers from ListWorkers API results by default. Users can opt in to seeing them via include_system_workers on the request.

Depends on API change: temporalio/api#777

Why

System workers (per-namespace workers for scheduler, batcher, worker deployment, etc.) appear in ListWorkers results, which is confusing for users who only care about their own workers.

How did you test it?

Unit tests.

🤖 Generated with Claude Code

rkannan82 and others added 6 commits April 29, 2026 15:53
System workers (on temporal-sys-* task queues) are now filtered out of
ListWorkers responses unless the caller sets IncludeSystemWorkers=true.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Covers both "temporal-sys-*" (e.g. temporal-sys-per-ns-tq) and
"/temporal-sys/*" (e.g. /temporal-sys/worker-commands/...) prefixes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Verifies that page sizes and tokens operate on the filtered set,
not the full set including system workers.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@rkannan82 rkannan82 requested a review from ShahabT April 30, 2026 20:37
@rkannan82 rkannan82 marked this pull request as ready for review April 30, 2026 20:41
@rkannan82 rkannan82 requested review from a team as code owners April 30, 2026 20:41
@rkannan82 rkannan82 marked this pull request as draft April 30, 2026 21:32
rkannan82 and others added 3 commits April 30, 2026 14:32
…me at query time

Moves the system worker classification to the entry level so it's computed
once during heartbeat recording rather than on every ListWorkers call.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Rename local variable for clarity
- Add test for filterWorkers with includeSystemWorkers=false
- Annotate bool args with /*includeSystemWorkers*/ for readability

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@rkannan82 rkannan82 marked this pull request as ready for review May 1, 2026 01:31
rkannan82 and others added 2 commits April 30, 2026 18:31
Note: this introduces a build failure in client/frontend due to the new
PauseActivityExecution RPC added in temporalio/api#743. That method needs
stubs before the full repo can build.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
rkannan82 and others added 3 commits April 30, 2026 20:09
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…xclude-system

# Conflicts:
#	common/primitives/task_queues.go
@rkannan82 rkannan82 enabled auto-merge (squash) May 2, 2026 00:21
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@rkannan82 rkannan82 merged commit 3a92940 into main May 2, 2026
47 checks passed
@rkannan82 rkannan82 deleted the kannan/list-workers-exclude-system branch May 2, 2026 00:49
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