-
Notifications
You must be signed in to change notification settings - Fork 5
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
doc: add cross-chain-communication-model.md #83
Conversation
WalkthroughThe document introduces the Cross-Chain Communication Model, detailing the interaction between multiple client chains and a singular Exocore chain. It describes the architecture of the communication framework, focusing on the Changes
Sequence Diagram(s)sequenceDiagram
participant ClientChainGateway
participant ExocoreGateway
participant ReceiverContract
ClientChainGateway->>ExocoreGateway: Send Message (Nonce)
ExocoreGateway->>ReceiverContract: Forward Message
ReceiverContract->>ReceiverContract: Process Message
ReceiverContract-->>ExocoreGateway: Acknowledge Success
ExocoreGateway-->>ClientChainGateway: Acknowledge Success
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Outside diff range, codebase verification and nitpick comments (2)
docs/cross-chain-communication-model.md (2)
1-2
: Add an introduction.Consider adding a brief introduction to provide context for the document. This will help readers understand the purpose and scope of the document.
20-23
: Add a comma before "and".The explanation of the blocking mechanism for message execution is clear and comprehensive. Consider adding a comma before "and" in the following sentence for better readability:
- the message is not stored and the nonce is not incremented + the message is not stored, and the nonce is not incrementedTools
LanguageTool
[uncategorized] ~22-~22: Use a comma before “and” if it connects two independent clauses (unless they are closely connected and short).
Context: ...e the message, the message is not stored and the nonce is not incremented, preventin...(COMMA_COMPOUND_SENTENCE_2)
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- docs/cross-chain-communication-model.md (1 hunks)
Additional context used
Learnings (1)
Common learnings
Learnt from: adu-web3 PR: ExocoreNetwork/exocore-contracts#39 File: src/core/ExocoreGateway.sol:105-105 Timestamp: 2024-07-01T09:18:36.140Z Learning: In the Exocore contracts, the design decision to avoid receiving responses from the client chain due to cost considerations means that operations assume success on the client chain.
LanguageTool
docs/cross-chain-communication-model.md
[uncategorized] ~22-~22: Use a comma before “and” if it connects two independent clauses (unless they are closely connected and short).
Context: ...e the message, the message is not stored and the nonce is not incremented, preventin...(COMMA_COMPOUND_SENTENCE_2)
Additional comments not posted (3)
docs/cross-chain-communication-model.md (3)
3-6
: LGTM!The explanation of the 1:N relationship is clear and concise.
7-18
: LGTM!The explanation of the nonce mechanism for ordered message execution is clear and comprehensive.
24-35
: LGTM!The explanation of the request-response mechanism and guidelines is clear and comprehensive.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
- As outlined in ExocoreNetwork#83, a cross-chain message that can't/won't be retried must not fail. Hence, all calls to `markBootstrapped` on `Bootstrap` should not fail. Fixes ExocoreNetwork#89 - Separately, sending multiple LZ messages in one transaction is convoluted and hence disabled. As a consequence, marking bootstrap on all chains is no longer supported; instead, the caller must provide the LZ chain ID. Along similar lines, the caller must provide the native fee for this transaction.
* fix(bootstrap): do not fail mark bootstrap - As outlined in #83, a cross-chain message that can't/won't be retried must not fail. Hence, all calls to `markBootstrapped` on `Bootstrap` should not fail. Fixes #89 - Separately, sending multiple LZ messages in one transaction is convoluted and hence disabled. As a consequence, marking bootstrap on all chains is no longer supported; instead, the caller must provide the LZ chain ID. Along similar lines, the caller must provide the native fee for this transaction. * fix: remove reference to markBootstrapOnAllChains * test: add unit test for mark bootstrap In the case where Bootstrap call first fails and then succeeds. * fix: do not fail mark bootstrap to gateway * fix(test): expect event * refactor: remove repeated code
Description
croos-chain-communication-model.md describes how messages are forwarded and executed between sender contract and receiver contract
Summary by CodeRabbit