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

performance: heartbeats and possibly timers are more expensive than required #4776

Open
crusso opened this issue Nov 22, 2024 · 0 comments
Open
Labels
performance Affects only gas usage or code size

Comments

@crusso
Copy link
Contributor

crusso commented Nov 22, 2024

A hearbeat is always executed in a separate message, causing 2 extra messages (3 in total). We can probably reduce the hearbeat to just a single message using an async* variant of the system method, or just 2 messages by using the fire-and-forget -1 callbacks when making the call.

A similar optimization might apply to timers, though we want to be careful to isolate the timer actions from each other and the maintenance of the priority queue (depends on how this is implemented).

https://dfinity.slack.com/archives/CPL67E7MX/p1732189506932589

@crusso crusso added the performance Affects only gas usage or code size label Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Affects only gas usage or code size
Projects
None yet
Development

No branches or pull requests

1 participant