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

Move contract emitted topics from being an actual topic to be just included into the event body #5629

Closed
Tracked by #5308
athei opened this issue Sep 6, 2024 · 0 comments · Fixed by #5640
Closed
Tracked by #5308
Assignees

Comments

@athei
Copy link
Member

athei commented Sep 6, 2024

No longer forward the topics that a contract passes as substrate topics ( https://paritytech.github.io/polkadot-sdk/master/frame_system/pallet/struct.Pallet.html#method.deposit_event_indexed ). Those are super costly as each of them incurs a storage write. Instead, just move them into the event body itself by adding a field for the topics here:

ContractEmitted {
/// The contract that emitted the event.
contract: H160,
/// Data supplied by the contract. Metadata generated during contract compilation
/// is needed to decode it.
data: Vec<u8>,
},

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants