Skip to content

Add support for worker versioning.#389

Open
EdsonPetry wants to merge 15 commits intodatafusion-contrib:mainfrom
EdsonPetry:edson.petry/worker-versioning
Open

Add support for worker versioning.#389
EdsonPetry wants to merge 15 commits intodatafusion-contrib:mainfrom
EdsonPetry:edson.petry/worker-versioning

Conversation

@EdsonPetry
Copy link
Copy Markdown
Contributor

Closes #380

Summary

  • Add GetWorkerInfo gRPC endpoint to worker.proto so workers can report a user-defined version string, enabling coordinators to filter by version during rolling deployments
  • Add Worker::with_version() builder method and export GetWorkerInfoRequest/GetWorkerInfoResponse from the crate root
  • Document the full versioning workflow in docs/
  • Update localhost_worker and localhost_run examples with --version flags

Fix broken code examples in worker.md: restore missing env var snippet,
correct proto field name (version_number → version), replace LruCache
with HashMap, fix misaligned zip iterator bug, and add channel_resolver
parameter to the resolver constructor.

Export get_worker_version() and add background_version_resolver to the
library for use by downstream consumers.
@EdsonPetry EdsonPetry force-pushed the edson.petry/worker-versioning branch from 9895b35 to 5b96300 Compare March 30, 2026 19:34
@EdsonPetry EdsonPetry force-pushed the edson.petry/worker-versioning branch from 8b4f825 to 815cdac Compare April 14, 2026 15:19
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

It'd be nice if we can keep the existing localhost_run.rs and localhost_worker.rs simple as before, and have either a specific example dedicated to versioning. What do you think?

Address PR review feedback:
- Remove `get_worker_version` helper (too trivial for a public API fn)
- Inline the RPC call in the docs example
- Restore `localhost_run.rs` and `localhost_worker.rs` to their simple
  pre-versioning state
- Add dedicated `localhost_versioned_run.rs` and
  `localhost_versioned_worker.rs` examples for version filtering
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.

Worker Versioning

2 participants