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

Message interpreter #289

Closed
aakoshh opened this issue Feb 2, 2023 · 0 comments · Fixed by consensus-shipyard/fendermint#14
Closed

Message interpreter #289

aakoshh opened this issue Feb 2, 2023 · 0 comments · Fixed by consensus-shipyard/fendermint#14

Comments

@aakoshh
Copy link
Contributor

aakoshh commented Feb 2, 2023

Implement the execution of chain messages using the FVM. Called an interpreter as a homage to https://github.com/ChainSafe/forest/tree/main/vm/interpreter

What's different for us from Forest is:

  • We get messages one by one from Tendermint Core, because that part of the ABCI interface hasn't changed. In later stages of ABCI++ rollout, the BeginBlock -> DeliverTx -> EndBlock -> Commit cycle will become FinalizeBlock (plus maybe a Commit).
  • The methods will be asynchronous, so they have a chance to do side effects when the message contains CIDs that need to be resolved.

So let's create an interpreter crate like Forest, with a abstract trait to apply messages on some state. The state will depend on the use case: during block execution it will be backed by copy-on-write cache of a block store, and similarly during transaction checking it will have a state that is based on the last executed block, with pending transaction applied but not committed. In Milestone 2 it will also have access to some shared memory through STM where it can coordinate the resolution of CIDs with the other parts of the application.

@jsoares jsoares transferred this issue from consensus-shipyard/fendermint Dec 19, 2023
@jsoares jsoares closed this as not planned Won't fix, can't repro, duplicate, stale Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants