clockworklabs / clockworklabs/SpacetimeDB
Record energy cost of module updates
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 25.2k
- Forks
- 1.1k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 46
Description
fn update_database, in crates/core/src/host/wasm_common/module_host_actor.rs , does not record the energy cost of the transaction which updates the database to a new module blob. It does record the cost of re-evaluating subscriptions if that's necessary, but not to write the system tables, which includes storing the new code blob.
Contributor guide
No contributing guide indexed for this repository
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 in crates/core/src/host/wasm_common/module_host_actor.rs at fn update_database. Read how subscription re-evaluation energy is recorded and trace the transaction that writes the system tables and new module blob. Done means the database update's energy cost is recorded consistently with the other transaction work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- databases
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 72/100