Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unique Worker ID #2529

Open
wants to merge 13 commits into
base: master
Choose a base branch
from

Conversation

whilenot-dev
Copy link

@whilenot-dev whilenot-dev commented Dec 5, 2024

Summary

Following this discussion, this is a draft to inject a unique worker ID into the app state of an application. Feedback welcome!

The worker ID should be consistent across restarts and provide the missing building block for idempotent startup- and shutdown routines in the lifespan of a worker.

Checklist

  • I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.

@whilenot-dev whilenot-dev changed the title Feat/unique worker Unique Worker ID Dec 5, 2024
@whilenot-dev
Copy link
Author

whilenot-dev commented Dec 5, 2024

Before I'll tackle the test coverage I'd like to have some feedback first:

  1. Should I limit the worker ID injection to multiprocess-mode only?
  2. Should I document the injection more like a warning? Can the injection be considered a bad sursprise?
  3. How about the simplicity, @Kludex? :D

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.

1 participant