Skip to content

feat(worker): wire GC job type to worker and admin-api#2010

Merged
mitchhs12 merged 1 commit intomainfrom
mitchhs12/worker-wiring
Mar 24, 2026
Merged

feat(worker): wire GC job type to worker and admin-api#2010
mitchhs12 merged 1 commit intomainfrom
mitchhs12/worker-wiring

Conversation

@mitchhs12
Copy link
Contributor

Summary

  • Adds Gc variant to the worker's JobDescriptor enum so GC jobs can be deserialized and dispatched
  • Adds GC match arm in worker job_impl.rs that builds a Context and calls amp_worker_gc::job_impl::execute()
  • Adds Gc variant to JobError with RetryableErrorExt, JobErrorExt, and ErrorDetailsProvider trait impls
  • Adds From<amp_worker_gc::job_descriptor::JobDescriptor> impl in admin-api scheduler
  • Adds GC display format in ampctl job list

Context

This is PR 2 of 3 splitting up the GC job extraction work:

  1. amp-worker-gc crate (merged in feat(amp-worker-gc): add standalone GC job crate #2009)
  2. This PR — wire to worker service
  3. Wire to scheduler + config + scheduler tests (depends on this PR)

Add GC job dispatch to the worker service so it can execute GC jobs
when notified by the controller. Adds the Gc variant to JobDescriptor,
JobError, and their trait impls. Adds From impl in admin-api scheduler
for GC job descriptors, and display format in ampctl job list.
@mitchhs12 mitchhs12 requested review from JohnSwan1503 and LNSD March 23, 2026 20:26
Copy link
Contributor

@LNSD LNSD left a comment

Choose a reason for hiding this comment

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

LGTM ✅

@mitchhs12 mitchhs12 merged commit 63e9f7d into main Mar 24, 2026
8 checks passed
@mitchhs12 mitchhs12 deleted the mitchhs12/worker-wiring branch March 24, 2026 14:37
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