Skip to content

NmtMaster: Delay heartbeat callbacks after state update (fixes #579) #601

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

acolomb
Copy link
Member

@acolomb acolomb commented Jul 15, 2025

Reduce the amount of code within the critical section holding the lock. Unpack and log first. Update timestamp and state while locked and notify condition waiters. Invoke callbacks after releasing the lock.

Based on the suggestion in #579 (comment), just without the added callback argument and without using a call() wrapper yet.

Reduce the amount of code within the critical section holding the
lock.  Unpack and log first.  Update timestamp and state while locked
and notify condition waiters.  Invoke callbacks after releasing the
lock.
@acolomb acolomb added this to the v3.0.0 milestone Jul 15, 2025
Copy link

codecov bot commented Jul 15, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

📢 Thoughts on this report? Let us know!

@acolomb acolomb linked an issue Jul 15, 2025 that may be closed by this pull request
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.

Order of operations in NmtMaster.on_heartbeat
1 participant