{"action":"created","issue":{"url":"https://api.github.com/repos/kasvith/kache/issues/19","repository_url":"https://api.github.com/repos/kasvith/kache","labels_url":"https://api.github.com/repos/kasvith/kache/issues/19/labels{/name}","comments_url":"https://api.github.com/repos/kasvith/kache/issues/19/comments","events_url":"https://api.github.com/repos/kasvith/kache/issues/19/events","html_url":"https://github.com/kasvith/kache/pull/19","id":352314290,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA5NjU3NDkw","number":19,"title":"switched to RWMutex to avoid fully locking if only reads occur","user":{"login":"BigJk","id":1621820,"node_id":"MDQ6VXNlcjE2MjE4MjA=","avatar_url":"https://avatars0.githubusercontent.com/u/1621820?v=4","gravatar_id":"","url":"https://api.github.com/users/BigJk","html_url":"https://github.com/BigJk","followers_url":"https://api.github.com/users/BigJk/followers","following_url":"https://api.github.com/users/BigJk/following{/other_user}","gists_url":"https://api.github.com/users/BigJk/gists{/gist_id}","starred_url":"https://api.github.com/users/BigJk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BigJk/subscriptions","organizations_url":"https://api.github.com/users/BigJk/orgs","repos_url":"https://api.github.com/users/BigJk/repos","events_url":"https://api.github.com/users/BigJk/events{/privacy}","received_events_url":"https://api.github.com/users/BigJk/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-08-20T22:09:16Z","updated_at":"2018-08-20T22:11:51Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/kasvith/kache/pulls/19","html_url":"https://github.com/kasvith/kache/pull/19","diff_url":"https://github.com/kasvith/kache/pull/19.diff","patch_url":"https://github.com/kasvith/kache/pull/19.patch"},"body":"# Pull Request for issue\r\n\r\nhttps://github.com/kasvith/kache/issues/17\r\n\r\n## Description\r\n\r\nSwitch 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. \r\n\r\n## Testing Instructions\r\n\r\n## Additional Comments\r\n\r\nAlso fixed a possible deadlock in the ``Diff`` method of the ``Set`` type. At the start of the ``Diff`` function the mutex was locked and only unlocked after the return while in the function itself the ``Elems`` method get's called which itself locks the mutex. This would produce a deadlock.\r\n"},"comment":{"url":"https://api.github.com/repos/kasvith/kache/issues/comments/414480153","html_url":"https://github.com/kasvith/kache/pull/19#issuecomment-414480153","issue_url":"https://api.github.com/repos/kasvith/kache/issues/19","id":414480153,"node_id":"MDEyOklzc3VlQ29tbWVudDQxNDQ4MDE1Mw==","user":{"login":"codecov[bot]","id":22429695,"node_id":"MDM6Qm90MjI0Mjk2OTU=","avatar_url":"https://avatars2.githubusercontent.com/in/254?v=4","gravatar_id":"","url":"https://api.github.com/users/codecov%5Bbot%5D","html_url":"https://github.com/apps/codecov","followers_url":"https://api.github.com/users/codecov%5Bbot%5D/followers","following_url":"https://api.github.com/users/codecov%5Bbot%5D/following{/other_user}","gists_url":"https://api.github.com/users/codecov%5Bbot%5D/gists{/gist_id}","starred_url":"https://api.github.com/users/codecov%5Bbot%5D/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codecov%5Bbot%5D/subscriptions","organizations_url":"https://api.github.com/users/codecov%5Bbot%5D/orgs","repos_url":"https://api.github.com/users/codecov%5Bbot%5D/repos","events_url":"https://api.github.com/users/codecov%5Bbot%5D/events{/privacy}","received_events_url":"https://api.github.com/users/codecov%5Bbot%5D/received_events","type":"Bot","site_admin":false},"created_at":"2018-08-20T22:11:51Z","updated_at":"2018-08-20T22:11:51Z","author_association":"NONE","body":"# [Codecov](https://codecov.io/gh/kasvith/kache/pull/19?src=pr&el=h1) Report\n> Merging [#19](https://codecov.io/gh/kasvith/kache/pull/19?src=pr&el=desc) into [master](https://codecov.io/gh/kasvith/kache/commit/aa3ba4bb97ce3a43ba8ac241cdd1c7627cb79e1c?src=pr&el=desc) will **not change** coverage.\n> The diff coverage is `100%`.\n\n[![Impacted file tree graph](https://codecov.io/gh/kasvith/kache/pull/19/graphs/tree.svg?src=pr&token=rhgjhEcPdY&width=650&height=150)](https://codecov.io/gh/kasvith/kache/pull/19?src=pr&el=tree)\n\n```diff\n@@         Coverage Diff          @@\n##           master   #19   +/-   ##\n====================================\n  Coverage      80%   80%           \n====================================\n  Files           8     8           \n  Lines         500   500           \n====================================\n  Hits          400   400           \n  Misses        100   100\n```\n\n\n| [Impacted Files](https://codecov.io/gh/kasvith/kache/pull/19?src=pr&el=tree) | Coverage Δ | |\n|---|---|---|\n| [pkg/types/hashmap/hmap.go](https://codecov.io/gh/kasvith/kache/pull/19/diff?src=pr&el=tree#diff-cGtnL3R5cGVzL2hhc2htYXAvaG1hcC5nbw==) | `100% <100%> (ø)` | :arrow_up: |\n| [pkg/types/list/list.go](https://codecov.io/gh/kasvith/kache/pull/19/diff?src=pr&el=tree#diff-cGtnL3R5cGVzL2xpc3QvbGlzdC5nbw==) | `99.04% <100%> (ø)` | :arrow_up: |\n| [pkg/types/set/set.go](https://codecov.io/gh/kasvith/kache/pull/19/diff?src=pr&el=tree#diff-cGtnL3R5cGVzL3NldC9zZXQuZ28=) | `100% <100%> (ø)` | :arrow_up: |\n\n------\n\n[Continue to review full report at Codecov](https://codecov.io/gh/kasvith/kache/pull/19?src=pr&el=continue).\n> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)\n> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`\n> Powered by [Codecov](https://codecov.io/gh/kasvith/kache/pull/19?src=pr&el=footer). Last update [aa3ba4b...25787d7](https://codecov.io/gh/kasvith/kache/pull/19?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).\n"}}
{"actor":{"display_login":"codecov"}}