Support non-shared callbacks
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 72
- Forks
- 16
- PR merge metrics
- No merged PRs in 30d
Description
Currently callbacks are implemented in a way that they can be shared, i.e. reused by multiple different requests and/or workflows. This made a lot of sense in the first iteration of bevy_impulse when everything was one-shot and repeatedly creating and dropping systems doesn't make much sense.
Now that workflows are fully reusable, there may be legitimate use cases where someone wants to drop a callback system into a specific node of a workflow and not reuse the system anywhere else. In those cases, there is an unnecessary mutex locking being done each time the node is run.
We can avoid the mutex lock if we have two flavors of callbacks: unique and shared.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the callback implementation and the workflow node execution path. Trace how callbacks are reused and where the mutex is acquired, then determine the API and behavior needed for unique and shared callback flavors. Done means unique callbacks avoid unnecessary mutex locking while shared callbacks remain reusable across requests or workflows.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100