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

chore: ensures consistent use of Lock and Unlock to acquire write-lock on the mempool v1 #1110

Merged
merged 3 commits into from
Oct 10, 2023

Conversation

staheri14
Copy link
Contributor

This PR refactors the mempool implementation to ensure consistent use of the Lock and Unlock methods for mutex management, promoting code reusability and traceability.

@staheri14 staheri14 self-assigned this Oct 6, 2023
@staheri14 staheri14 marked this pull request as ready for review October 6, 2023 22:31
Copy link
Collaborator

@rootulp rootulp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Based on this It looks like txmp.Unlock() is a wrapper around txmp.mtx.Unlock() and similar for Unlock. Given those methods exist, I think it makes sense to actually use them.

also 👍 godoc fixes

@staheri14 staheri14 merged commit 0da5e1d into main Oct 10, 2023
15 checks passed
@staheri14 staheri14 deleted the sanaz/uses-exported-Unlock-Lock branch October 10, 2023 16: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.

4 participants