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

fix: Fix interval inconsistent behavior #378

Merged
merged 1 commit into from
Nov 20, 2024

Conversation

driftluo
Copy link
Collaborator

https://github.com/nervosnetwork/tentacle/blob/master/tentacle/src/runtime/generic_timer.rs#L19

generic timer uses Delay to implement interval, its behavior is to wake up after the delay time, and then reset the delay. tokio timer interval wakes up immediately without delay, we should use interval_at to set interval start instant to make them have consistent behavior

@driftluo driftluo requested a review from eval-exec as a code owner November 20, 2024 02:14
@driftluo driftluo merged commit f4baf2a into master Nov 20, 2024
7 checks passed
@driftluo driftluo deleted the fix-interval-inconsistent-behavior branch November 20, 2024 02:36
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 this pull request may close these issues.

2 participants