{"action":"created","issue":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/7504","repository_url":"https://api.github.com/repos/cockroachdb/cockroach","labels_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/7504/labels{/name}","comments_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/7504/comments","events_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/7504/events","html_url":"https://github.com/cockroachdb/cockroach/pull/7504","id":162715211,"number":7504,"title":"sql: avoid deadlock in lease acquisition","user":{"login":"andreimatei","id":377201,"avatar_url":"https://avatars.githubusercontent.com/u/377201?v=3","gravatar_id":"","url":"https://api.github.com/users/andreimatei","html_url":"https://github.com/andreimatei","followers_url":"https://api.github.com/users/andreimatei/followers","following_url":"https://api.github.com/users/andreimatei/following{/other_user}","gists_url":"https://api.github.com/users/andreimatei/gists{/gist_id}","starred_url":"https://api.github.com/users/andreimatei/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andreimatei/subscriptions","organizations_url":"https://api.github.com/users/andreimatei/orgs","repos_url":"https://api.github.com/users/andreimatei/repos","events_url":"https://api.github.com/users/andreimatei/events{/privacy}","received_events_url":"https://api.github.com/users/andreimatei/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2016-06-28T15:29:07Z","updated_at":"2016-06-29T14:35:57Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/cockroachdb/cockroach/pulls/7504","html_url":"https://github.com/cockroachdb/cockroach/pull/7504","diff_url":"https://github.com/cockroachdb/cockroach/pull/7504.diff","patch_url":"https://github.com/cockroachdb/cockroach/pull/7504.patch"},"body":"We were locking leaseState, tableNameCache in Release(), but\r\ntableNameCache,LeaseState in AcquireByName.\r\nRefactored Release() to not require both locks at the same time.\n\n<!-- Reviewable:start -->\n---\nThis change is [<img src=\"https://reviewable.io/review_button.svg\" height=\"35\" align=\"absmiddle\" alt=\"Reviewable\"/>](https://reviewable.io/reviews/cockroachdb/cockroach/7504)\n<!-- Reviewable:end -->\n"},"comment":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/comments/229375656","html_url":"https://github.com/cockroachdb/cockroach/pull/7504#issuecomment-229375656","issue_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/7504","id":229375656,"user":{"login":"vivekmenezes","id":11774212,"avatar_url":"https://avatars.githubusercontent.com/u/11774212?v=3","gravatar_id":"","url":"https://api.github.com/users/vivekmenezes","html_url":"https://github.com/vivekmenezes","followers_url":"https://api.github.com/users/vivekmenezes/followers","following_url":"https://api.github.com/users/vivekmenezes/following{/other_user}","gists_url":"https://api.github.com/users/vivekmenezes/gists{/gist_id}","starred_url":"https://api.github.com/users/vivekmenezes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vivekmenezes/subscriptions","organizations_url":"https://api.github.com/users/vivekmenezes/orgs","repos_url":"https://api.github.com/users/vivekmenezes/repos","events_url":"https://api.github.com/users/vivekmenezes/events{/privacy}","received_events_url":"https://api.github.com/users/vivekmenezes/received_events","type":"User","site_admin":false},"created_at":"2016-06-29T14:35:57Z","updated_at":"2016-06-29T14:35:57Z","body":"\n\n\n\nReview status: all files reviewed at latest revision, 5 unresolved discussions, some commit checks failed.\n\n---\n\n*[sql/lease.go, line 684 \\[r1\\]](https://reviewable.io:443/reviews/cockroachdb/cockroach/7504#-KLMhNJqR42JeXAc9dhQ:-KLR_Y8fjL0QYATH8xmQ:-1302183745) ([raw file](https://github.com/cockroachdb/cockroach/blob/c80d81782d3618a3e236c5bbda1a9857e75465a1/sql/lease.go#L684)):*\n<details><summary><i>Previously, vivekmenezes wrote…</i></summary>\n> None here; we will have to plumb one in\n</details>\nHey I'm okay with you creating a new PR for that\n\n---\n\n\n*Comments from [Reviewable](https://reviewable.io:443/reviews/cockroachdb/cockroach/7504)*\n<!-- Sent from Reviewable.io -->\n"}}
{"actor":{"display_login":"vivekmenezes"}}