paritytech / paritytech/host-rust-core
RFC: Calling a product worker from its app
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 10
- Forks
- 3
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 148
Description
Source PR: #468 · docs/rfcs/0027-surface-worker-calls.md · @BigTava
Description
A Worker trait adds call_worker, which invokes a named export of the calling product's own worker with a JSON payload and returns the answer.
Motivation
A product's views and its worker have no protocol between them, so work meant to outlive the view runs in the page and dies with it. Without a bounded call, products will ask to hand the worker a function instead.
Requirements
- The request carries no product id — the Host supplies the caller identity.
api_namemust be an export the verified archive already declared; nothing loads on demand.deadline_msdefaults to and is clamped by the Host window.- Errors are
Unavailable | Invalid | Timeout | Crashed | Version, withUnavailableundifferentiated on purpose. - The worker manifest declares which executables may call it.
Tasks
- RFC document body
- Implementation — rust-core
- Implementation — hosts
- dotli
- Desktop
- iOS
- Android
- host-cli
Note: RFC number 0027 is also claimed by #420.
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 with docs/rfcs/0027-surface-worker-calls.md and the source PR #468, then review the requirements and the rust-core and host implementation task list. Confirm how the RFC number conflict with #420 is resolved. Done means the RFC body and the listed rust-core, dotli, Desktop, iOS, Android, and host-cli work are addressed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- api, backend-api-design
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100