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

ref(k8s): Add a k8s for the taskworker deployment #114

Merged
merged 2 commits into from
Jan 10, 2025

Conversation

evanh
Copy link
Member

@evanh evanh commented Jan 9, 2025

This adds a k8s file for deploying the taskworker image. It also makes a few QoL improvements:

  • Replace SimpleTaskWorker with ConfigurableTaskWorker
  • Add more logging to the worker
  • Add a backoff to the worker, so that if there are no messages it doesn't spam logs
  • Update the taskbroker image
  • Fix a bug in the worker where it wouldn't process tasks fetched in the update

This adds a k8s file for deploying the taskworker image. It also makes a few QoL improvements:

- Replace SimpleTaskWorker with ConfigurableTaskWorker
- Add more logging to the worker
- Add a backoff to the worker, so that if there are no messages it doesn't spam logs
- Update the taskbroker image
- Fix a bug in the worker where it wouldn't process tasks fetched in the update
@evanh evanh requested a review from a team as a code owner January 9, 2025 17:10
k8s/README.md Outdated Show resolved Hide resolved
@@ -32,7 +31,7 @@ def manage_taskworker(
shutdown_event: threading.Event,
) -> None:
print(f"[taskworker_{worker_id}] Starting taskworker_{worker_id}")
worker = SimpleTaskWorker(
worker = ConfigurableTaskWorker(
Copy link
Member

Choose a reason for hiding this comment

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

Just FYI: I also updated this test in my PR. If this goes out first, I'll fix it: #112

Co-authored-by: Mark Story <[email protected]>
@evanh evanh merged commit cc30423 into main Jan 10, 2025
9 checks passed
@evanh evanh deleted the evanh/feat/add-taskworker-to-k8s branch January 10, 2025 16:12
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.

4 participants