{"action":"created","comment":{"url":"https://api.github.com/repos/linkedin/ambry/pulls/comments/66183188","id":66183188,"diff_hunk":"@@ -138,17 +153,22 @@ public NetworkClient(Selector selector, NetworkConfig networkConfig, int maxConn\n             connId = selector.connect(new InetSocketAddress(host, port.getPort()), networkConfig.socketSendBufferBytes,\n                 networkConfig.socketReceiveBufferBytes, port.getPortType());\n             connectionTracker.startTrackingInitiatedConnection(host, port, connId);\n+            requestMetadata.connectionCheckOutAttempts++;\n           }\n         } else {\n-          sends.add(new NetworkSend(connId, requestMetadata.requestInfo.getRequest(), null, time));\n+          sends.add(new NetworkSend(connId, requestMetadata.requestInfo.getRequest(),\n+              requestMetadata.clientNetworkRequestMetrics, time));\n           connectionIdToRequestInFlight.put(connId, requestMetadata);\n           iter.remove();\n+          numPendingConnections.set(pendingRequests.size());","path":"ambry-network/src/main/java/com.github.ambry.network/NetworkClient.java","position":90,"original_position":90,"commit_id":"1bcb0e5115fa83fcac41fa5a97be30ad774b840f","original_commit_id":"1bcb0e5115fa83fcac41fa5a97be30ad774b840f","user":{"login":"nsivabalan","id":513218,"avatar_url":"https://avatars.githubusercontent.com/u/513218?v=3","gravatar_id":"","url":"https://api.github.com/users/nsivabalan","html_url":"https://github.com/nsivabalan","followers_url":"https://api.github.com/users/nsivabalan/followers","following_url":"https://api.github.com/users/nsivabalan/following{/other_user}","gists_url":"https://api.github.com/users/nsivabalan/gists{/gist_id}","starred_url":"https://api.github.com/users/nsivabalan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nsivabalan/subscriptions","organizations_url":"https://api.github.com/users/nsivabalan/orgs","repos_url":"https://api.github.com/users/nsivabalan/repos","events_url":"https://api.github.com/users/nsivabalan/events{/privacy}","received_events_url":"https://api.github.com/users/nsivabalan/received_events","type":"User","site_admin":false},"body":"Yes, I went over the processor and selector and there are no issues in multiple selectors updating the metrics. Similarly, here even though multiple network clients might update the same metric, no issues, just that we will get an aggregated view","created_at":"2016-06-08T02:05:33Z","updated_at":"2016-06-08T02:05:33Z","html_url":"https://github.com/linkedin/ambry/pull/331#discussion_r66183188","pull_request_url":"https://api.github.com/repos/linkedin/ambry/pulls/331","_links":{"self":{"href":"https://api.github.com/repos/linkedin/ambry/pulls/comments/66183188"},"html":{"href":"https://github.com/linkedin/ambry/pull/331#discussion_r66183188"},"pull_request":{"href":"https://api.github.com/repos/linkedin/ambry/pulls/331"}}},"pull_request":{"url":"https://api.github.com/repos/linkedin/ambry/pulls/331","id":71159425,"html_url":"https://github.com/linkedin/ambry/pull/331","diff_url":"https://github.com/linkedin/ambry/pull/331.diff","patch_url":"https://github.com/linkedin/ambry/pull/331.patch","issue_url":"https://api.github.com/repos/linkedin/ambry/issues/331","number":331,"state":"open","locked":false,"title":"Adding metrics to NetworkClient","user":{"login":"nsivabalan","id":513218,"avatar_url":"https://avatars.githubusercontent.com/u/513218?v=3","gravatar_id":"","url":"https://api.github.com/users/nsivabalan","html_url":"https://github.com/nsivabalan","followers_url":"https://api.github.com/users/nsivabalan/followers","following_url":"https://api.github.com/users/nsivabalan/following{/other_user}","gists_url":"https://api.github.com/users/nsivabalan/gists{/gist_id}","starred_url":"https://api.github.com/users/nsivabalan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nsivabalan/subscriptions","organizations_url":"https://api.github.com/users/nsivabalan/orgs","repos_url":"https://api.github.com/users/nsivabalan/repos","events_url":"https://api.github.com/users/nsivabalan/events{/privacy}","received_events_url":"https://api.github.com/users/nsivabalan/received_events","type":"User","site_admin":false},"body":"Adding metrics to NetworkClient. \r\n\r\nSLA: 20 mins\r\nReviewers: Priyesh, Ming\r\n\r\nSome notes to assist in reviewing:\r\nStage1: 5 mins\r\nRenamed the class and some variables in NetworkRequestMetircs to NetworkSendMetrics.\r\nClasses that calls into NetworkSendMetrics (just renamed):\r\nNetworkSend, RequestResponseChannel, SocketRequestResponseChannel, AmbryRequests\r\n\r\nStage2: 15 mins\r\nNetworkClient and NetworkMetrics\r\nThis has the major change in this patch. Introduced new metrics to track metrics for NetworkClient. Also have rearranged existing metrics in NetworkMetrics a bit.\r\nMisc classes: NetworkClientFactory, NetworkClientTest, MockNetworkClientFactory, ","created_at":"2016-05-24T05:23:42Z","updated_at":"2016-06-08T02:05:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8f2cfb66e56e5ff0778bb8877c0f165cee69178e","assignee":{"login":"pnarayanan","id":1454915,"avatar_url":"https://avatars.githubusercontent.com/u/1454915?v=3","gravatar_id":"","url":"https://api.github.com/users/pnarayanan","html_url":"https://github.com/pnarayanan","followers_url":"https://api.github.com/users/pnarayanan/followers","following_url":"https://api.github.com/users/pnarayanan/following{/other_user}","gists_url":"https://api.github.com/users/pnarayanan/gists{/gist_id}","starred_url":"https://api.github.com/users/pnarayanan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pnarayanan/subscriptions","organizations_url":"https://api.github.com/users/pnarayanan/orgs","repos_url":"https://api.github.com/users/pnarayanan/repos","events_url":"https://api.github.com/users/pnarayanan/events{/privacy}","received_events_url":"https://api.github.com/users/pnarayanan/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/linkedin/ambry/pulls/331/commits","review_comments_url":"https://api.github.com/repos/linkedin/ambry/pulls/331/comments","review_comment_url":"https://api.github.com/repos/linkedin/ambry/pulls/comments{/number}","comments_url":"https://api.github.com/repos/linkedin/ambry/issues/331/comments","statuses_url":"https://api.github.com/repos/linkedin/ambry/statuses/1bcb0e5115fa83fcac41fa5a97be30ad774b840f","head":{"label":"nsivabalan:networkClientMetrics","ref":"networkClientMetrics","sha":"1bcb0e5115fa83fcac41fa5a97be30ad774b840f","user":{"login":"nsivabalan","id":513218,"avatar_url":"https://avatars.githubusercontent.com/u/513218?v=3","gravatar_id":"","url":"https://api.github.com/users/nsivabalan","html_url":"https://github.com/nsivabalan","followers_url":"https://api.github.com/users/nsivabalan/followers","following_url":"https://api.github.com/users/nsivabalan/following{/other_user}","gists_url":"https://api.github.com/users/nsivabalan/gists{/gist_id}","starred_url":"https://api.github.com/users/nsivabalan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nsivabalan/subscriptions","organizations_url":"https://api.github.com/users/nsivabalan/orgs","repos_url":"https://api.github.com/users/nsivabalan/repos","events_url":"https://api.github.com/users/nsivabalan/events{/privacy}","received_events_url":"https://api.github.com/users/nsivabalan/received_events","type":"User","site_admin":false},"repo":{"id":20119917,"name":"ambry","full_name":"nsivabalan/ambry","owner":{"login":"nsivabalan","id":513218,"avatar_url":"https://avatars.githubusercontent.com/u/513218?v=3","gravatar_id":"","url":"https://api.github.com/users/nsivabalan","html_url":"https://github.com/nsivabalan","followers_url":"https://api.github.com/users/nsivabalan/followers","following_url":"https://api.github.com/users/nsivabalan/following{/other_user}","gists_url":"https://api.github.com/users/nsivabalan/gists{/gist_id}","starred_url":"https://api.github.com/users/nsivabalan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nsivabalan/subscriptions","organizations_url":"https://api.github.com/users/nsivabalan/orgs","repos_url":"https://api.github.com/users/nsivabalan/repos","events_url":"https://api.github.com/users/nsivabalan/events{/privacy}","received_events_url":"https://api.github.com/users/nsivabalan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nsivabalan/ambry","description":"Immutable blob store","fork":true,"url":"https://api.github.com/repos/nsivabalan/ambry","forks_url":"https://api.github.com/repos/nsivabalan/ambry/forks","keys_url":"https://api.github.com/repos/nsivabalan/ambry/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nsivabalan/ambry/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nsivabalan/ambry/teams","hooks_url":"https://api.github.com/repos/nsivabalan/ambry/hooks","issue_events_url":"https://api.github.com/repos/nsivabalan/ambry/issues/events{/number}","events_url":"https://api.github.com/repos/nsivabalan/ambry/events","assignees_url":"https://api.github.com/repos/nsivabalan/ambry/assignees{/user}","branches_url":"https://api.github.com/repos/nsivabalan/ambry/branches{/branch}","tags_url":"https://api.github.com/repos/nsivabalan/ambry/tags","blobs_url":"https://api.github.com/repos/nsivabalan/ambry/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nsivabalan/ambry/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nsivabalan/ambry/git/refs{/sha}","trees_url":"https://api.github.com/repos/nsivabalan/ambry/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nsivabalan/ambry/statuses/{sha}","languages_url":"https://api.github.com/repos/nsivabalan/ambry/languages","stargazers_url":"https://api.github.com/repos/nsivabalan/ambry/stargazers","contributors_url":"https://api.github.com/repos/nsivabalan/ambry/contributors","subscribers_url":"https://api.github.com/repos/nsivabalan/ambry/subscribers","subscription_url":"https://api.github.com/repos/nsivabalan/ambry/subscription","commits_url":"https://api.github.com/repos/nsivabalan/ambry/commits{/sha}","git_commits_url":"https://api.github.com/repos/nsivabalan/ambry/git/commits{/sha}","comments_url":"https://api.github.com/repos/nsivabalan/ambry/comments{/number}","issue_comment_url":"https://api.github.com/repos/nsivabalan/ambry/issues/comments{/number}","contents_url":"https://api.github.com/repos/nsivabalan/ambry/contents/{+path}","compare_url":"https://api.github.com/repos/nsivabalan/ambry/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nsivabalan/ambry/merges","archive_url":"https://api.github.com/repos/nsivabalan/ambry/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nsivabalan/ambry/downloads","issues_url":"https://api.github.com/repos/nsivabalan/ambry/issues{/number}","pulls_url":"https://api.github.com/repos/nsivabalan/ambry/pulls{/number}","milestones_url":"https://api.github.com/repos/nsivabalan/ambry/milestones{/number}","notifications_url":"https://api.github.com/repos/nsivabalan/ambry/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nsivabalan/ambry/labels{/name}","releases_url":"https://api.github.com/repos/nsivabalan/ambry/releases{/id}","deployments_url":"https://api.github.com/repos/nsivabalan/ambry/deployments","created_at":"2014-05-24T02:15:09Z","updated_at":"2016-05-04T20:45:58Z","pushed_at":"2016-06-07T22:26:07Z","git_url":"git://github.com/nsivabalan/ambry.git","ssh_url":"git@github.com:nsivabalan/ambry.git","clone_url":"https://github.com/nsivabalan/ambry.git","svn_url":"https://github.com/nsivabalan/ambry","homepage":null,"size":6828,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"linkedin:master","ref":"master","sha":"9362e993eddf537f2e4f003cd38939be266473e1","user":{"login":"linkedin","id":357098,"avatar_url":"https://avatars.githubusercontent.com/u/357098?v=3","gravatar_id":"","url":"https://api.github.com/users/linkedin","html_url":"https://github.com/linkedin","followers_url":"https://api.github.com/users/linkedin/followers","following_url":"https://api.github.com/users/linkedin/following{/other_user}","gists_url":"https://api.github.com/users/linkedin/gists{/gist_id}","starred_url":"https://api.github.com/users/linkedin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/linkedin/subscriptions","organizations_url":"https://api.github.com/users/linkedin/orgs","repos_url":"https://api.github.com/users/linkedin/repos","events_url":"https://api.github.com/users/linkedin/events{/privacy}","received_events_url":"https://api.github.com/users/linkedin/received_events","type":"Organization","site_admin":false},"repo":{"id":13870893,"name":"ambry","full_name":"linkedin/ambry","owner":{"login":"linkedin","id":357098,"avatar_url":"https://avatars.githubusercontent.com/u/357098?v=3","gravatar_id":"","url":"https://api.github.com/users/linkedin","html_url":"https://github.com/linkedin","followers_url":"https://api.github.com/users/linkedin/followers","following_url":"https://api.github.com/users/linkedin/following{/other_user}","gists_url":"https://api.github.com/users/linkedin/gists{/gist_id}","starred_url":"https://api.github.com/users/linkedin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/linkedin/subscriptions","organizations_url":"https://api.github.com/users/linkedin/orgs","repos_url":"https://api.github.com/users/linkedin/repos","events_url":"https://api.github.com/users/linkedin/events{/privacy}","received_events_url":"https://api.github.com/users/linkedin/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/linkedin/ambry","description":"Distributed object store","fork":false,"url":"https://api.github.com/repos/linkedin/ambry","forks_url":"https://api.github.com/repos/linkedin/ambry/forks","keys_url":"https://api.github.com/repos/linkedin/ambry/keys{/key_id}","collaborators_url":"https://api.github.com/repos/linkedin/ambry/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/linkedin/ambry/teams","hooks_url":"https://api.github.com/repos/linkedin/ambry/hooks","issue_events_url":"https://api.github.com/repos/linkedin/ambry/issues/events{/number}","events_url":"https://api.github.com/repos/linkedin/ambry/events","assignees_url":"https://api.github.com/repos/linkedin/ambry/assignees{/user}","branches_url":"https://api.github.com/repos/linkedin/ambry/branches{/branch}","tags_url":"https://api.github.com/repos/linkedin/ambry/tags","blobs_url":"https://api.github.com/repos/linkedin/ambry/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/linkedin/ambry/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/linkedin/ambry/git/refs{/sha}","trees_url":"https://api.github.com/repos/linkedin/ambry/git/trees{/sha}","statuses_url":"https://api.github.com/repos/linkedin/ambry/statuses/{sha}","languages_url":"https://api.github.com/repos/linkedin/ambry/languages","stargazers_url":"https://api.github.com/repos/linkedin/ambry/stargazers","contributors_url":"https://api.github.com/repos/linkedin/ambry/contributors","subscribers_url":"https://api.github.com/repos/linkedin/ambry/subscribers","subscription_url":"https://api.github.com/repos/linkedin/ambry/subscription","commits_url":"https://api.github.com/repos/linkedin/ambry/commits{/sha}","git_commits_url":"https://api.github.com/repos/linkedin/ambry/git/commits{/sha}","comments_url":"https://api.github.com/repos/linkedin/ambry/comments{/number}","issue_comment_url":"https://api.github.com/repos/linkedin/ambry/issues/comments{/number}","contents_url":"https://api.github.com/repos/linkedin/ambry/contents/{+path}","compare_url":"https://api.github.com/repos/linkedin/ambry/compare/{base}...{head}","merges_url":"https://api.github.com/repos/linkedin/ambry/merges","archive_url":"https://api.github.com/repos/linkedin/ambry/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/linkedin/ambry/downloads","issues_url":"https://api.github.com/repos/linkedin/ambry/issues{/number}","pulls_url":"https://api.github.com/repos/linkedin/ambry/pulls{/number}","milestones_url":"https://api.github.com/repos/linkedin/ambry/milestones{/number}","notifications_url":"https://api.github.com/repos/linkedin/ambry/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/linkedin/ambry/labels{/name}","releases_url":"https://api.github.com/repos/linkedin/ambry/releases{/id}","deployments_url":"https://api.github.com/repos/linkedin/ambry/deployments","created_at":"2013-10-25T20:04:54Z","updated_at":"2016-06-07T21:14:24Z","pushed_at":"2016-06-08T01:28:40Z","git_url":"git://github.com/linkedin/ambry.git","ssh_url":"git@github.com:linkedin/ambry.git","clone_url":"https://github.com/linkedin/ambry.git","svn_url":"https://github.com/linkedin/ambry","homepage":"https://github.com/linkedin/ambry/wiki","size":7874,"stargazers_count":579,"watchers_count":579,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":62,"mirror_url":null,"open_issues_count":27,"forks":62,"open_issues":27,"watchers":579,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/linkedin/ambry/pulls/331"},"html":{"href":"https://github.com/linkedin/ambry/pull/331"},"issue":{"href":"https://api.github.com/repos/linkedin/ambry/issues/331"},"comments":{"href":"https://api.github.com/repos/linkedin/ambry/issues/331/comments"},"review_comments":{"href":"https://api.github.com/repos/linkedin/ambry/pulls/331/comments"},"review_comment":{"href":"https://api.github.com/repos/linkedin/ambry/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/linkedin/ambry/pulls/331/commits"},"statuses":{"href":"https://api.github.com/repos/linkedin/ambry/statuses/1bcb0e5115fa83fcac41fa5a97be30ad774b840f"}}}}
{"actor":{"display_login":"nsivabalan"}}