{"action":"created","comment":{"url":"https://api.github.com/repos/mesos/mesos-go/pulls/comments/40301831","id":40301831,"diff_hunk":"@@ -337,3 +302,49 @@ func makeMockServer(path string, handler func(rsp http.ResponseWriter, req *http\n \tmux.HandleFunc(path, handler)\n \treturn httptest.NewServer(mux)\n }\n+\n+func TestProcessOneRequest(t *testing.T) {\n+\tht := &HTTPTransporter{\n+\t\tmessageQueue: make(chan *Message, 1),\n+\t\tshouldQuit:   make(chan struct{}),\n+\t}\n+\ttestfunc := func(expectProceed bool) {\n+\t\trchan := make(chan Response, 1)\n+\t\tproceed := ht.processOneRequest(&upid.UPID{ID: \"james\"}, &Request{\n+\t\t\tresponse: rchan,\n+\t\t\tRequest: &http.Request{\n+\t\t\t\tMethod:     \"foo\",\n+\t\t\t\tRequestURI: \"a/z/bar\",\n+\t\t\t\tBody:       ioutil.NopCloser(bytes.NewBuffer([]byte{})),","path":"messenger/http_transporter_test.go","position":224,"original_position":224,"commit_id":"070843bdb254c33ec0b6dd2ebbe6ad172c6395c7","original_commit_id":"070843bdb254c33ec0b6dd2ebbe6ad172c6395c7","user":{"login":"tsenart","id":67471,"avatar_url":"https://avatars.githubusercontent.com/u/67471?v=3","gravatar_id":"","url":"https://api.github.com/users/tsenart","html_url":"https://github.com/tsenart","followers_url":"https://api.github.com/users/tsenart/followers","following_url":"https://api.github.com/users/tsenart/following{/other_user}","gists_url":"https://api.github.com/users/tsenart/gists{/gist_id}","starred_url":"https://api.github.com/users/tsenart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tsenart/subscriptions","organizations_url":"https://api.github.com/users/tsenart/orgs","repos_url":"https://api.github.com/users/tsenart/repos","events_url":"https://api.github.com/users/tsenart/events{/privacy}","received_events_url":"https://api.github.com/users/tsenart/received_events","type":"User","site_admin":false},"body":"`s/bytes.NewBuffer/bytes.Reader{}`","created_at":"2015-09-24T09:46:36Z","updated_at":"2015-09-24T09:46:36Z","html_url":"https://github.com/mesos/mesos-go/pull/189#discussion_r40301831","pull_request_url":"https://api.github.com/repos/mesos/mesos-go/pulls/189","_links":{"self":{"href":"https://api.github.com/repos/mesos/mesos-go/pulls/comments/40301831"},"html":{"href":"https://github.com/mesos/mesos-go/pull/189#discussion_r40301831"},"pull_request":{"href":"https://api.github.com/repos/mesos/mesos-go/pulls/189"}}},"pull_request":{"url":"https://api.github.com/repos/mesos/mesos-go/pulls/189","id":45686133,"html_url":"https://github.com/mesos/mesos-go/pull/189","diff_url":"https://github.com/mesos/mesos-go/pull/189.diff","patch_url":"https://github.com/mesos/mesos-go/pull/189.patch","issue_url":"https://api.github.com/repos/mesos/mesos-go/issues/189","number":189,"state":"open","locked":false,"title":"fix racy UPID access and intermittent scheduler deadlock at shutdown time","user":{"login":"jdef","id":2348332,"avatar_url":"https://avatars.githubusercontent.com/u/2348332?v=3","gravatar_id":"","url":"https://api.github.com/users/jdef","html_url":"https://github.com/jdef","followers_url":"https://api.github.com/users/jdef/followers","following_url":"https://api.github.com/users/jdef/following{/other_user}","gists_url":"https://api.github.com/users/jdef/gists{/gist_id}","starred_url":"https://api.github.com/users/jdef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdef/subscriptions","organizations_url":"https://api.github.com/users/jdef/orgs","repos_url":"https://api.github.com/users/jdef/repos","events_url":"https://api.github.com/users/jdef/events{/privacy}","received_events_url":"https://api.github.com/users/jdef/received_events","type":"User","site_admin":false},"body":"- UPID pointer sharing between transporter and messenger was awful - cleaned it up\r\n- during integration testing, noticed that scheduler sometimes hung at shutdown - fixed that\r\n  - the `withScheduler` construct is looking uglier and uglier, though it is somewhat contained to the factory func that builds the func; there must be a simpler solution here.\r\n- libprocess decoder fixes\r\n  - check for ECONNRESET for graceful connection termination\r\n  - reading Request's should't block if shouldQuit chan is closed\r\n- unit tests were not happy after the above changes, fixed them","created_at":"2015-09-22T16:31:40Z","updated_at":"2015-09-24T09:46:37Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8f2c11a491cc2dd6626406edacb12267f9a51d10","assignee":{"login":"tsenart","id":67471,"avatar_url":"https://avatars.githubusercontent.com/u/67471?v=3","gravatar_id":"","url":"https://api.github.com/users/tsenart","html_url":"https://github.com/tsenart","followers_url":"https://api.github.com/users/tsenart/followers","following_url":"https://api.github.com/users/tsenart/following{/other_user}","gists_url":"https://api.github.com/users/tsenart/gists{/gist_id}","starred_url":"https://api.github.com/users/tsenart/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tsenart/subscriptions","organizations_url":"https://api.github.com/users/tsenart/orgs","repos_url":"https://api.github.com/users/tsenart/repos","events_url":"https://api.github.com/users/tsenart/events{/privacy}","received_events_url":"https://api.github.com/users/tsenart/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/mesos/mesos-go/pulls/189/commits","review_comments_url":"https://api.github.com/repos/mesos/mesos-go/pulls/189/comments","review_comment_url":"https://api.github.com/repos/mesos/mesos-go/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mesos/mesos-go/issues/189/comments","statuses_url":"https://api.github.com/repos/mesos/mesos-go/statuses/070843bdb254c33ec0b6dd2ebbe6ad172c6395c7","head":{"label":"jdef:master","ref":"master","sha":"070843bdb254c33ec0b6dd2ebbe6ad172c6395c7","user":{"login":"jdef","id":2348332,"avatar_url":"https://avatars.githubusercontent.com/u/2348332?v=3","gravatar_id":"","url":"https://api.github.com/users/jdef","html_url":"https://github.com/jdef","followers_url":"https://api.github.com/users/jdef/followers","following_url":"https://api.github.com/users/jdef/following{/other_user}","gists_url":"https://api.github.com/users/jdef/gists{/gist_id}","starred_url":"https://api.github.com/users/jdef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdef/subscriptions","organizations_url":"https://api.github.com/users/jdef/orgs","repos_url":"https://api.github.com/users/jdef/repos","events_url":"https://api.github.com/users/jdef/events{/privacy}","received_events_url":"https://api.github.com/users/jdef/received_events","type":"User","site_admin":false},"repo":{"id":27655809,"name":"mesos-go","full_name":"jdef/mesos-go","owner":{"login":"jdef","id":2348332,"avatar_url":"https://avatars.githubusercontent.com/u/2348332?v=3","gravatar_id":"","url":"https://api.github.com/users/jdef","html_url":"https://github.com/jdef","followers_url":"https://api.github.com/users/jdef/followers","following_url":"https://api.github.com/users/jdef/following{/other_user}","gists_url":"https://api.github.com/users/jdef/gists{/gist_id}","starred_url":"https://api.github.com/users/jdef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdef/subscriptions","organizations_url":"https://api.github.com/users/jdef/orgs","repos_url":"https://api.github.com/users/jdef/repos","events_url":"https://api.github.com/users/jdef/events{/privacy}","received_events_url":"https://api.github.com/users/jdef/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jdef/mesos-go","description":"Go language bindings for Apache Mesos","fork":true,"url":"https://api.github.com/repos/jdef/mesos-go","forks_url":"https://api.github.com/repos/jdef/mesos-go/forks","keys_url":"https://api.github.com/repos/jdef/mesos-go/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jdef/mesos-go/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jdef/mesos-go/teams","hooks_url":"https://api.github.com/repos/jdef/mesos-go/hooks","issue_events_url":"https://api.github.com/repos/jdef/mesos-go/issues/events{/number}","events_url":"https://api.github.com/repos/jdef/mesos-go/events","assignees_url":"https://api.github.com/repos/jdef/mesos-go/assignees{/user}","branches_url":"https://api.github.com/repos/jdef/mesos-go/branches{/branch}","tags_url":"https://api.github.com/repos/jdef/mesos-go/tags","blobs_url":"https://api.github.com/repos/jdef/mesos-go/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jdef/mesos-go/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jdef/mesos-go/git/refs{/sha}","trees_url":"https://api.github.com/repos/jdef/mesos-go/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jdef/mesos-go/statuses/{sha}","languages_url":"https://api.github.com/repos/jdef/mesos-go/languages","stargazers_url":"https://api.github.com/repos/jdef/mesos-go/stargazers","contributors_url":"https://api.github.com/repos/jdef/mesos-go/contributors","subscribers_url":"https://api.github.com/repos/jdef/mesos-go/subscribers","subscription_url":"https://api.github.com/repos/jdef/mesos-go/subscription","commits_url":"https://api.github.com/repos/jdef/mesos-go/commits{/sha}","git_commits_url":"https://api.github.com/repos/jdef/mesos-go/git/commits{/sha}","comments_url":"https://api.github.com/repos/jdef/mesos-go/comments{/number}","issue_comment_url":"https://api.github.com/repos/jdef/mesos-go/issues/comments{/number}","contents_url":"https://api.github.com/repos/jdef/mesos-go/contents/{+path}","compare_url":"https://api.github.com/repos/jdef/mesos-go/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jdef/mesos-go/merges","archive_url":"https://api.github.com/repos/jdef/mesos-go/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jdef/mesos-go/downloads","issues_url":"https://api.github.com/repos/jdef/mesos-go/issues{/number}","pulls_url":"https://api.github.com/repos/jdef/mesos-go/pulls{/number}","milestones_url":"https://api.github.com/repos/jdef/mesos-go/milestones{/number}","notifications_url":"https://api.github.com/repos/jdef/mesos-go/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jdef/mesos-go/labels{/name}","releases_url":"https://api.github.com/repos/jdef/mesos-go/releases{/id}","created_at":"2014-12-07T01:46:53Z","updated_at":"2015-02-13T23:14:15Z","pushed_at":"2015-09-23T21:30:20Z","git_url":"git://github.com/jdef/mesos-go.git","ssh_url":"git@github.com:jdef/mesos-go.git","clone_url":"https://github.com/jdef/mesos-go.git","svn_url":"https://github.com/jdef/mesos-go","homepage":"","size":9786,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mesos:master","ref":"master","sha":"2c798f0d1d87ec3f5d7475dfa11903d4a6de4be8","user":{"login":"mesos","id":229272,"avatar_url":"https://avatars.githubusercontent.com/u/229272?v=3","gravatar_id":"","url":"https://api.github.com/users/mesos","html_url":"https://github.com/mesos","followers_url":"https://api.github.com/users/mesos/followers","following_url":"https://api.github.com/users/mesos/following{/other_user}","gists_url":"https://api.github.com/users/mesos/gists{/gist_id}","starred_url":"https://api.github.com/users/mesos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mesos/subscriptions","organizations_url":"https://api.github.com/users/mesos/orgs","repos_url":"https://api.github.com/users/mesos/repos","events_url":"https://api.github.com/users/mesos/events{/privacy}","received_events_url":"https://api.github.com/users/mesos/received_events","type":"Organization","site_admin":false},"repo":{"id":14454411,"name":"mesos-go","full_name":"mesos/mesos-go","owner":{"login":"mesos","id":229272,"avatar_url":"https://avatars.githubusercontent.com/u/229272?v=3","gravatar_id":"","url":"https://api.github.com/users/mesos","html_url":"https://github.com/mesos","followers_url":"https://api.github.com/users/mesos/followers","following_url":"https://api.github.com/users/mesos/following{/other_user}","gists_url":"https://api.github.com/users/mesos/gists{/gist_id}","starred_url":"https://api.github.com/users/mesos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mesos/subscriptions","organizations_url":"https://api.github.com/users/mesos/orgs","repos_url":"https://api.github.com/users/mesos/repos","events_url":"https://api.github.com/users/mesos/events{/privacy}","received_events_url":"https://api.github.com/users/mesos/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mesos/mesos-go","description":"Go language bindings for Apache Mesos","fork":false,"url":"https://api.github.com/repos/mesos/mesos-go","forks_url":"https://api.github.com/repos/mesos/mesos-go/forks","keys_url":"https://api.github.com/repos/mesos/mesos-go/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mesos/mesos-go/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mesos/mesos-go/teams","hooks_url":"https://api.github.com/repos/mesos/mesos-go/hooks","issue_events_url":"https://api.github.com/repos/mesos/mesos-go/issues/events{/number}","events_url":"https://api.github.com/repos/mesos/mesos-go/events","assignees_url":"https://api.github.com/repos/mesos/mesos-go/assignees{/user}","branches_url":"https://api.github.com/repos/mesos/mesos-go/branches{/branch}","tags_url":"https://api.github.com/repos/mesos/mesos-go/tags","blobs_url":"https://api.github.com/repos/mesos/mesos-go/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mesos/mesos-go/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mesos/mesos-go/git/refs{/sha}","trees_url":"https://api.github.com/repos/mesos/mesos-go/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mesos/mesos-go/statuses/{sha}","languages_url":"https://api.github.com/repos/mesos/mesos-go/languages","stargazers_url":"https://api.github.com/repos/mesos/mesos-go/stargazers","contributors_url":"https://api.github.com/repos/mesos/mesos-go/contributors","subscribers_url":"https://api.github.com/repos/mesos/mesos-go/subscribers","subscription_url":"https://api.github.com/repos/mesos/mesos-go/subscription","commits_url":"https://api.github.com/repos/mesos/mesos-go/commits{/sha}","git_commits_url":"https://api.github.com/repos/mesos/mesos-go/git/commits{/sha}","comments_url":"https://api.github.com/repos/mesos/mesos-go/comments{/number}","issue_comment_url":"https://api.github.com/repos/mesos/mesos-go/issues/comments{/number}","contents_url":"https://api.github.com/repos/mesos/mesos-go/contents/{+path}","compare_url":"https://api.github.com/repos/mesos/mesos-go/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mesos/mesos-go/merges","archive_url":"https://api.github.com/repos/mesos/mesos-go/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mesos/mesos-go/downloads","issues_url":"https://api.github.com/repos/mesos/mesos-go/issues{/number}","pulls_url":"https://api.github.com/repos/mesos/mesos-go/pulls{/number}","milestones_url":"https://api.github.com/repos/mesos/mesos-go/milestones{/number}","notifications_url":"https://api.github.com/repos/mesos/mesos-go/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mesos/mesos-go/labels{/name}","releases_url":"https://api.github.com/repos/mesos/mesos-go/releases{/id}","created_at":"2013-11-16T20:40:30Z","updated_at":"2015-09-19T17:49:40Z","pushed_at":"2015-09-23T21:30:20Z","git_url":"git://github.com/mesos/mesos-go.git","ssh_url":"git@github.com:mesos/mesos-go.git","clone_url":"https://github.com/mesos/mesos-go.git","svn_url":"https://github.com/mesos/mesos-go","homepage":"","size":10753,"stargazers_count":246,"watchers_count":246,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":63,"mirror_url":null,"open_issues_count":23,"forks":63,"open_issues":23,"watchers":246,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mesos/mesos-go/pulls/189"},"html":{"href":"https://github.com/mesos/mesos-go/pull/189"},"issue":{"href":"https://api.github.com/repos/mesos/mesos-go/issues/189"},"comments":{"href":"https://api.github.com/repos/mesos/mesos-go/issues/189/comments"},"review_comments":{"href":"https://api.github.com/repos/mesos/mesos-go/pulls/189/comments"},"review_comment":{"href":"https://api.github.com/repos/mesos/mesos-go/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mesos/mesos-go/pulls/189/commits"},"statuses":{"href":"https://api.github.com/repos/mesos/mesos-go/statuses/070843bdb254c33ec0b6dd2ebbe6ad172c6395c7"}}}}