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

switched to RWMutex to avoid fully locking if only reads occur #19

Merged
merged 1 commit into from Aug 21, 2018

Conversation

Projects
None yet
2 participants
@BigJk
Contributor

BigJk commented Aug 20, 2018

Pull Request for issue

#17

Description

Switch from Mutex to RWMutex. Parallel read operations shouldn't lock up the whole structure, thus a RWMutex makes more sense in this scenario to speedup reading.

Testing Instructions

Additional Comments

@codecov

This comment has been minimized.

Show comment
Hide comment
@codecov

codecov bot Aug 20, 2018

Codecov Report

Merging #19 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@         Coverage Diff          @@
##           master   #19   +/-   ##
====================================
  Coverage      80%   80%           
====================================
  Files           8     8           
  Lines         500   500           
====================================
  Hits          400   400           
  Misses        100   100
Impacted Files Coverage Δ
pkg/types/list/list.go 99.04% <100%> (ø) ⬆️
pkg/types/hashmap/hmap.go 100% <100%> (ø) ⬆️
pkg/types/set/set.go 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update aa3ba4b...25787d7. Read the comment docs.

codecov bot commented Aug 20, 2018

Codecov Report

Merging #19 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@         Coverage Diff          @@
##           master   #19   +/-   ##
====================================
  Coverage      80%   80%           
====================================
  Files           8     8           
  Lines         500   500           
====================================
  Hits          400   400           
  Misses        100   100
Impacted Files Coverage Δ
pkg/types/list/list.go 99.04% <100%> (ø) ⬆️
pkg/types/hashmap/hmap.go 100% <100%> (ø) ⬆️
pkg/types/set/set.go 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update aa3ba4b...25787d7. Read the comment docs.

@kasvith

great work

@kasvith kasvith added the accepted label Aug 21, 2018

@kasvith kasvith merged commit 180acc4 into kasvith:master Aug 21, 2018

4 checks passed

codecov/patch 100% of diff hit (target 80%)
Details
codecov/project 80% (+0%) compared to aa3ba4b
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@kasvith kasvith referenced this pull request Aug 21, 2018

Closed

Replace Mutexes with RWMutexes #17

3 of 3 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment