{"action":"created","comment":{"url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/comments/56137534","id":56137534,"diff_hunk":"@@ -324,9 +331,46 @@ private Game getGameFromJson(JSONObject gameObj) {\n         return null;\n     }\n \n-    private String getControllerId(Game gameToJoin) {\n+    private String getStreamingPort(Game gameToJoin) {\n         try {\n+            URL url = new URL(baseurl + String.format(\"/game-session/?game=%s&user=%s\",\n+                                                      gameToJoin.getId(),\n+                                                      loginUsername.getText()));\n+            HttpURLConnection connection = (HttpURLConnection) url.openConnection();\n+\n+            String auth = \"Token \" + token;\n+\n+            connection.setRequestMethod(\"GET\");\n+            connection.setRequestProperty(\"Authorization\", auth);\n+            connection.setRequestProperty(\"Accept\", \"application/json\");\n+","path":"CloudyLauncher.java","position":50,"original_position":50,"commit_id":"a6621b3b04d968e98db7876b53b3f35731443ae0","original_commit_id":"a6621b3b04d968e98db7876b53b3f35731443ae0","user":{"login":"bloodelves88","id":4394614,"avatar_url":"https://avatars.githubusercontent.com/u/4394614?v=3","gravatar_id":"","url":"https://api.github.com/users/bloodelves88","html_url":"https://github.com/bloodelves88","followers_url":"https://api.github.com/users/bloodelves88/followers","following_url":"https://api.github.com/users/bloodelves88/following{/other_user}","gists_url":"https://api.github.com/users/bloodelves88/gists{/gist_id}","starred_url":"https://api.github.com/users/bloodelves88/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bloodelves88/subscriptions","organizations_url":"https://api.github.com/users/bloodelves88/orgs","repos_url":"https://api.github.com/users/bloodelves88/repos","events_url":"https://api.github.com/users/bloodelves88/events{/privacy}","received_events_url":"https://api.github.com/users/bloodelves88/received_events","type":"User","site_admin":false},"body":"Might want to put all this HTTP connection stuff into a function","created_at":"2016-03-15T09:49:56Z","updated_at":"2016-03-15T09:49:56Z","html_url":"https://github.com/insert-coin/CloudyGameThinClient/pull/33#discussion_r56137534","pull_request_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33","_links":{"self":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/comments/56137534"},"html":{"href":"https://github.com/insert-coin/CloudyGameThinClient/pull/33#discussion_r56137534"},"pull_request":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33"}}},"pull_request":{"url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33","id":62491198,"html_url":"https://github.com/insert-coin/CloudyGameThinClient/pull/33","diff_url":"https://github.com/insert-coin/CloudyGameThinClient/pull/33.diff","patch_url":"https://github.com/insert-coin/CloudyGameThinClient/pull/33.patch","issue_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/33","number":33,"state":"open","locked":false,"title":"Launcher integrate join game","user":{"login":"zeanne","id":7569773,"avatar_url":"https://avatars.githubusercontent.com/u/7569773?v=3","gravatar_id":"","url":"https://api.github.com/users/zeanne","html_url":"https://github.com/zeanne","followers_url":"https://api.github.com/users/zeanne/followers","following_url":"https://api.github.com/users/zeanne/following{/other_user}","gists_url":"https://api.github.com/users/zeanne/gists{/gist_id}","starred_url":"https://api.github.com/users/zeanne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zeanne/subscriptions","organizations_url":"https://api.github.com/users/zeanne/orgs","repos_url":"https://api.github.com/users/zeanne/repos","events_url":"https://api.github.com/users/zeanne/events{/privacy}","received_events_url":"https://api.github.com/users/zeanne/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-03-11T02:56:55Z","updated_at":"2016-03-15T09:49:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"83ed55db559f9efa42470792e709e6a4e41e40e1","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33/commits","review_comments_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33/comments","review_comment_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/comments{/number}","comments_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/33/comments","statuses_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/statuses/a6621b3b04d968e98db7876b53b3f35731443ae0","head":{"label":"insert-coin:launcher-integrateJoinGame","ref":"launcher-integrateJoinGame","sha":"a6621b3b04d968e98db7876b53b3f35731443ae0","user":{"login":"insert-coin","id":14160971,"avatar_url":"https://avatars.githubusercontent.com/u/14160971?v=3","gravatar_id":"","url":"https://api.github.com/users/insert-coin","html_url":"https://github.com/insert-coin","followers_url":"https://api.github.com/users/insert-coin/followers","following_url":"https://api.github.com/users/insert-coin/following{/other_user}","gists_url":"https://api.github.com/users/insert-coin/gists{/gist_id}","starred_url":"https://api.github.com/users/insert-coin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/insert-coin/subscriptions","organizations_url":"https://api.github.com/users/insert-coin/orgs","repos_url":"https://api.github.com/users/insert-coin/repos","events_url":"https://api.github.com/users/insert-coin/events{/privacy}","received_events_url":"https://api.github.com/users/insert-coin/received_events","type":"Organization","site_admin":false},"repo":{"id":45387831,"name":"CloudyGameThinClient","full_name":"insert-coin/CloudyGameThinClient","owner":{"login":"insert-coin","id":14160971,"avatar_url":"https://avatars.githubusercontent.com/u/14160971?v=3","gravatar_id":"","url":"https://api.github.com/users/insert-coin","html_url":"https://github.com/insert-coin","followers_url":"https://api.github.com/users/insert-coin/followers","following_url":"https://api.github.com/users/insert-coin/following{/other_user}","gists_url":"https://api.github.com/users/insert-coin/gists{/gist_id}","starred_url":"https://api.github.com/users/insert-coin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/insert-coin/subscriptions","organizations_url":"https://api.github.com/users/insert-coin/orgs","repos_url":"https://api.github.com/users/insert-coin/repos","events_url":"https://api.github.com/users/insert-coin/events{/privacy}","received_events_url":"https://api.github.com/users/insert-coin/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/insert-coin/CloudyGameThinClient","description":"This is an application that the player uses to play the game.","fork":false,"url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient","forks_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/forks","keys_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/keys{/key_id}","collaborators_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/teams","hooks_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/hooks","issue_events_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/events{/number}","events_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/events","assignees_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/assignees{/user}","branches_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/branches{/branch}","tags_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/tags","blobs_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/refs{/sha}","trees_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/trees{/sha}","statuses_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/statuses/{sha}","languages_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/languages","stargazers_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/stargazers","contributors_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/contributors","subscribers_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/subscribers","subscription_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/subscription","commits_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/commits{/sha}","git_commits_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/commits{/sha}","comments_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/comments{/number}","issue_comment_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/comments{/number}","contents_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/contents/{+path}","compare_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/compare/{base}...{head}","merges_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/merges","archive_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/downloads","issues_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues{/number}","pulls_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls{/number}","milestones_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/milestones{/number}","notifications_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/labels{/name}","releases_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/releases{/id}","deployments_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/deployments","created_at":"2015-11-02T10:30:29Z","updated_at":"2016-02-14T07:28:44Z","pushed_at":"2016-03-11T04:34:35Z","git_url":"git://github.com/insert-coin/CloudyGameThinClient.git","ssh_url":"git@github.com:insert-coin/CloudyGameThinClient.git","clone_url":"https://github.com/insert-coin/CloudyGameThinClient.git","svn_url":"https://github.com/insert-coin/CloudyGameThinClient","homepage":"","size":179,"stargazers_count":1,"watchers_count":1,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":4,"forks":2,"open_issues":4,"watchers":1,"default_branch":"master"}},"base":{"label":"insert-coin:master","ref":"master","sha":"87776b1567a1d3f4497fb8d7f0d1f94314270bfb","user":{"login":"insert-coin","id":14160971,"avatar_url":"https://avatars.githubusercontent.com/u/14160971?v=3","gravatar_id":"","url":"https://api.github.com/users/insert-coin","html_url":"https://github.com/insert-coin","followers_url":"https://api.github.com/users/insert-coin/followers","following_url":"https://api.github.com/users/insert-coin/following{/other_user}","gists_url":"https://api.github.com/users/insert-coin/gists{/gist_id}","starred_url":"https://api.github.com/users/insert-coin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/insert-coin/subscriptions","organizations_url":"https://api.github.com/users/insert-coin/orgs","repos_url":"https://api.github.com/users/insert-coin/repos","events_url":"https://api.github.com/users/insert-coin/events{/privacy}","received_events_url":"https://api.github.com/users/insert-coin/received_events","type":"Organization","site_admin":false},"repo":{"id":45387831,"name":"CloudyGameThinClient","full_name":"insert-coin/CloudyGameThinClient","owner":{"login":"insert-coin","id":14160971,"avatar_url":"https://avatars.githubusercontent.com/u/14160971?v=3","gravatar_id":"","url":"https://api.github.com/users/insert-coin","html_url":"https://github.com/insert-coin","followers_url":"https://api.github.com/users/insert-coin/followers","following_url":"https://api.github.com/users/insert-coin/following{/other_user}","gists_url":"https://api.github.com/users/insert-coin/gists{/gist_id}","starred_url":"https://api.github.com/users/insert-coin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/insert-coin/subscriptions","organizations_url":"https://api.github.com/users/insert-coin/orgs","repos_url":"https://api.github.com/users/insert-coin/repos","events_url":"https://api.github.com/users/insert-coin/events{/privacy}","received_events_url":"https://api.github.com/users/insert-coin/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/insert-coin/CloudyGameThinClient","description":"This is an application that the player uses to play the game.","fork":false,"url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient","forks_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/forks","keys_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/keys{/key_id}","collaborators_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/teams","hooks_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/hooks","issue_events_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/events{/number}","events_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/events","assignees_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/assignees{/user}","branches_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/branches{/branch}","tags_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/tags","blobs_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/refs{/sha}","trees_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/trees{/sha}","statuses_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/statuses/{sha}","languages_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/languages","stargazers_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/stargazers","contributors_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/contributors","subscribers_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/subscribers","subscription_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/subscription","commits_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/commits{/sha}","git_commits_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/git/commits{/sha}","comments_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/comments{/number}","issue_comment_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/comments{/number}","contents_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/contents/{+path}","compare_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/compare/{base}...{head}","merges_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/merges","archive_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/downloads","issues_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues{/number}","pulls_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls{/number}","milestones_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/milestones{/number}","notifications_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/labels{/name}","releases_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/releases{/id}","deployments_url":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/deployments","created_at":"2015-11-02T10:30:29Z","updated_at":"2016-02-14T07:28:44Z","pushed_at":"2016-03-11T04:34:35Z","git_url":"git://github.com/insert-coin/CloudyGameThinClient.git","ssh_url":"git@github.com:insert-coin/CloudyGameThinClient.git","clone_url":"https://github.com/insert-coin/CloudyGameThinClient.git","svn_url":"https://github.com/insert-coin/CloudyGameThinClient","homepage":"","size":179,"stargazers_count":1,"watchers_count":1,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":4,"forks":2,"open_issues":4,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33"},"html":{"href":"https://github.com/insert-coin/CloudyGameThinClient/pull/33"},"issue":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/33"},"comments":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/issues/33/comments"},"review_comments":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33/comments"},"review_comment":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/pulls/33/commits"},"statuses":{"href":"https://api.github.com/repos/insert-coin/CloudyGameThinClient/statuses/a6621b3b04d968e98db7876b53b3f35731443ae0"}}}}