Skip to content

feat(TaskProducer): lazy load inner producer#670

Merged
bmckerry merged 1 commit into
mainfrom
ben/task-producer-factory
Jun 3, 2026
Merged

feat(TaskProducer): lazy load inner producer#670
bmckerry merged 1 commit into
mainfrom
ben/task-producer-factory

Conversation

@bmckerry
Copy link
Copy Markdown
Member

@bmckerry bmckerry commented Jun 3, 2026

Changes the TaskProducer to take a factory function that returns a producer, rather than a producer object itself. This will make replacing sentry's SingletonProducer more straightforward, as that takes a producer factory and generates it lazily like this.

Also updates the TaskProducer docstring to be slightly clearer.

@bmckerry bmckerry requested a review from a team as a code owner June 3, 2026 14:35
Comment thread clients/python/src/taskbroker_client/worker/producer.py
@bmckerry bmckerry force-pushed the ben/task-producer-factory branch from 06ce9eb to 40bc3a5 Compare June 3, 2026 14:44
Comment thread clients/python/src/taskbroker_client/worker/producer.py Outdated
@bmckerry bmckerry force-pushed the ben/task-producer-factory branch from 40bc3a5 to 2e515a9 Compare June 3, 2026 14:47
@bmckerry bmckerry merged commit 499c190 into main Jun 3, 2026
26 checks passed
@bmckerry bmckerry deleted the ben/task-producer-factory branch June 3, 2026 15:10
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