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

feat(Semaphore): add waiterCount to reveal the number of locked resources #44

Merged
merged 2 commits into from
Sep 24, 2024

Conversation

lambdalisue
Copy link
Member

@lambdalisue lambdalisue commented Sep 24, 2024

Close #43

The name suggested was lockedSize but while Notify has waiterCount attribute that is quite similar to this, I added waiterCount attribute instead.

@lambdalisue lambdalisue marked this pull request as draft September 24, 2024 03:08
Copy link

codecov bot commented Sep 24, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.48%. Comparing base (ece8b39) to head (7a8c10b).
Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #44      +/-   ##
==========================================
+ Coverage   93.33%   93.48%   +0.15%     
==========================================
  Files          17       17              
  Lines         420      430      +10     
  Branches       38       38              
==========================================
+ Hits          392      402      +10     
  Misses         28       28              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@alexgleason
Copy link

This looks great!! Thank you very much!

@lambdalisue lambdalisue changed the title feat(Semaphore): add lockedSize to reveal the number of locked resources feat(Semaphore): add waiterCount to reveal the number of locked resources Sep 24, 2024
@lambdalisue lambdalisue marked this pull request as ready for review September 24, 2024 19:38
@lambdalisue
Copy link
Member Author

@alexgleason Note that the attribute is renamed to waiterCount.

@lambdalisue lambdalisue merged commit 7fae845 into main Sep 24, 2024
6 checks passed
@lambdalisue lambdalisue deleted the semaphore-size branch September 24, 2024 19:39
@alexgleason
Copy link

Thank you very much!

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.

Get number of current locks in semaphore
2 participants