{"action":"created","comment":{"url":"https://api.github.com/repos/allegro/akubra/pulls/comments/188848101","pull_request_review_id":120906722,"id":188848101,"diff_hunk":"@@ -0,0 +1,70 @@\n+package discovery\n+\n+import (\n+\t\"fmt\"\n+\t\"math/rand\"\n+\t\"net/url\"\n+\t\"time\"\n+\n+\t\"sync\"\n+\t\"sync/atomic\"\n+\t\"unsafe\"\n+\n+\t\"github.com/hashicorp/consul/api\"\n+)\n+\n+// Resolver for discovery service\n+type Resolver struct {\n+\tconsulClient    *api.Client\n+\tendpoints       []*url.URL\n+\tcurrentEndpoint *url.URL\n+\tgenerator       *rand.Rand\n+\tCacheTTL        int64","path":"discovery/resolver.go","position":22,"original_position":22,"commit_id":"02098e043e5428602275091403d7e72e025cc666","original_commit_id":"02098e043e5428602275091403d7e72e025cc666","user":{"login":"ksitak","id":23630697,"avatar_url":"https://avatars2.githubusercontent.com/u/23630697?v=4","gravatar_id":"","url":"https://api.github.com/users/ksitak","html_url":"https://github.com/ksitak","followers_url":"https://api.github.com/users/ksitak/followers","following_url":"https://api.github.com/users/ksitak/following{/other_user}","gists_url":"https://api.github.com/users/ksitak/gists{/gist_id}","starred_url":"https://api.github.com/users/ksitak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ksitak/subscriptions","organizations_url":"https://api.github.com/users/ksitak/orgs","repos_url":"https://api.github.com/users/ksitak/repos","events_url":"https://api.github.com/users/ksitak/events{/privacy}","received_events_url":"https://api.github.com/users/ksitak/received_events","type":"User","site_admin":false},"body":"lastUpdateTime?","created_at":"2018-05-17T06:15:58Z","updated_at":"2018-05-17T06:15:58Z","html_url":"https://github.com/allegro/akubra/pull/89#discussion_r188848101","pull_request_url":"https://api.github.com/repos/allegro/akubra/pulls/89","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/allegro/akubra/pulls/comments/188848101"},"html":{"href":"https://github.com/allegro/akubra/pull/89#discussion_r188848101"},"pull_request":{"href":"https://api.github.com/repos/allegro/akubra/pulls/89"}}},"pull_request":{"url":"https://api.github.com/repos/allegro/akubra/pulls/89","id":187005235,"html_url":"https://github.com/allegro/akubra/pull/89","diff_url":"https://github.com/allegro/akubra/pull/89.diff","patch_url":"https://github.com/allegro/akubra/pull/89.patch","issue_url":"https://api.github.com/repos/allegro/akubra/issues/89","number":89,"state":"open","locked":false,"title":"sync tasks log by service discovered from consul","user":{"login":"bieli","id":183053,"avatar_url":"https://avatars1.githubusercontent.com/u/183053?v=4","gravatar_id":"","url":"https://api.github.com/users/bieli","html_url":"https://github.com/bieli","followers_url":"https://api.github.com/users/bieli/followers","following_url":"https://api.github.com/users/bieli/following{/other_user}","gists_url":"https://api.github.com/users/bieli/gists{/gist_id}","starred_url":"https://api.github.com/users/bieli/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bieli/subscriptions","organizations_url":"https://api.github.com/users/bieli/orgs","repos_url":"https://api.github.com/users/bieli/repos","events_url":"https://api.github.com/users/bieli/events{/privacy}","received_events_url":"https://api.github.com/users/bieli/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-05-09T18:38:39Z","updated_at":"2018-05-17T06:15:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3999b06fe6d4b3aaab2f000d4807d06ba9ae7dbc","assignee":null,"assignees":[],"requested_reviewers":[{"login":"mjarco","id":535518,"avatar_url":"https://avatars1.githubusercontent.com/u/535518?v=4","gravatar_id":"","url":"https://api.github.com/users/mjarco","html_url":"https://github.com/mjarco","followers_url":"https://api.github.com/users/mjarco/followers","following_url":"https://api.github.com/users/mjarco/following{/other_user}","gists_url":"https://api.github.com/users/mjarco/gists{/gist_id}","starred_url":"https://api.github.com/users/mjarco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mjarco/subscriptions","organizations_url":"https://api.github.com/users/mjarco/orgs","repos_url":"https://api.github.com/users/mjarco/repos","events_url":"https://api.github.com/users/mjarco/events{/privacy}","received_events_url":"https://api.github.com/users/mjarco/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/allegro/akubra/pulls/89/commits","review_comments_url":"https://api.github.com/repos/allegro/akubra/pulls/89/comments","review_comment_url":"https://api.github.com/repos/allegro/akubra/pulls/comments{/number}","comments_url":"https://api.github.com/repos/allegro/akubra/issues/89/comments","statuses_url":"https://api.github.com/repos/allegro/akubra/statuses/02098e043e5428602275091403d7e72e025cc666","head":{"label":"allegro:v1.0--sync-task-by-service-from-consul-discovery","ref":"v1.0--sync-task-by-service-from-consul-discovery","sha":"02098e043e5428602275091403d7e72e025cc666","user":{"login":"allegro","id":562236,"avatar_url":"https://avatars3.githubusercontent.com/u/562236?v=4","gravatar_id":"","url":"https://api.github.com/users/allegro","html_url":"https://github.com/allegro","followers_url":"https://api.github.com/users/allegro/followers","following_url":"https://api.github.com/users/allegro/following{/other_user}","gists_url":"https://api.github.com/users/allegro/gists{/gist_id}","starred_url":"https://api.github.com/users/allegro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/allegro/subscriptions","organizations_url":"https://api.github.com/users/allegro/orgs","repos_url":"https://api.github.com/users/allegro/repos","events_url":"https://api.github.com/users/allegro/events{/privacy}","received_events_url":"https://api.github.com/users/allegro/received_events","type":"Organization","site_admin":false},"repo":{"id":71782347,"name":"akubra","full_name":"allegro/akubra","owner":{"login":"allegro","id":562236,"avatar_url":"https://avatars3.githubusercontent.com/u/562236?v=4","gravatar_id":"","url":"https://api.github.com/users/allegro","html_url":"https://github.com/allegro","followers_url":"https://api.github.com/users/allegro/followers","following_url":"https://api.github.com/users/allegro/following{/other_user}","gists_url":"https://api.github.com/users/allegro/gists{/gist_id}","starred_url":"https://api.github.com/users/allegro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/allegro/subscriptions","organizations_url":"https://api.github.com/users/allegro/orgs","repos_url":"https://api.github.com/users/allegro/repos","events_url":"https://api.github.com/users/allegro/events{/privacy}","received_events_url":"https://api.github.com/users/allegro/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/allegro/akubra","description":"Simple solution to keep a independent S3 storages in sync","fork":false,"url":"https://api.github.com/repos/allegro/akubra","forks_url":"https://api.github.com/repos/allegro/akubra/forks","keys_url":"https://api.github.com/repos/allegro/akubra/keys{/key_id}","collaborators_url":"https://api.github.com/repos/allegro/akubra/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/allegro/akubra/teams","hooks_url":"https://api.github.com/repos/allegro/akubra/hooks","issue_events_url":"https://api.github.com/repos/allegro/akubra/issues/events{/number}","events_url":"https://api.github.com/repos/allegro/akubra/events","assignees_url":"https://api.github.com/repos/allegro/akubra/assignees{/user}","branches_url":"https://api.github.com/repos/allegro/akubra/branches{/branch}","tags_url":"https://api.github.com/repos/allegro/akubra/tags","blobs_url":"https://api.github.com/repos/allegro/akubra/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/allegro/akubra/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/allegro/akubra/git/refs{/sha}","trees_url":"https://api.github.com/repos/allegro/akubra/git/trees{/sha}","statuses_url":"https://api.github.com/repos/allegro/akubra/statuses/{sha}","languages_url":"https://api.github.com/repos/allegro/akubra/languages","stargazers_url":"https://api.github.com/repos/allegro/akubra/stargazers","contributors_url":"https://api.github.com/repos/allegro/akubra/contributors","subscribers_url":"https://api.github.com/repos/allegro/akubra/subscribers","subscription_url":"https://api.github.com/repos/allegro/akubra/subscription","commits_url":"https://api.github.com/repos/allegro/akubra/commits{/sha}","git_commits_url":"https://api.github.com/repos/allegro/akubra/git/commits{/sha}","comments_url":"https://api.github.com/repos/allegro/akubra/comments{/number}","issue_comment_url":"https://api.github.com/repos/allegro/akubra/issues/comments{/number}","contents_url":"https://api.github.com/repos/allegro/akubra/contents/{+path}","compare_url":"https://api.github.com/repos/allegro/akubra/compare/{base}...{head}","merges_url":"https://api.github.com/repos/allegro/akubra/merges","archive_url":"https://api.github.com/repos/allegro/akubra/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/allegro/akubra/downloads","issues_url":"https://api.github.com/repos/allegro/akubra/issues{/number}","pulls_url":"https://api.github.com/repos/allegro/akubra/pulls{/number}","milestones_url":"https://api.github.com/repos/allegro/akubra/milestones{/number}","notifications_url":"https://api.github.com/repos/allegro/akubra/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/allegro/akubra/labels{/name}","releases_url":"https://api.github.com/repos/allegro/akubra/releases{/id}","deployments_url":"https://api.github.com/repos/allegro/akubra/deployments","created_at":"2016-10-24T11:32:11Z","updated_at":"2018-04-24T21:54:35Z","pushed_at":"2018-05-16T14:26:12Z","git_url":"git://github.com/allegro/akubra.git","ssh_url":"git@github.com:allegro/akubra.git","clone_url":"https://github.com/allegro/akubra.git","svn_url":"https://github.com/allegro/akubra","homepage":"","size":8944,"stargazers_count":49,"watchers_count":49,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":4,"open_issues":6,"watchers":49,"default_branch":"master"}},"base":{"label":"allegro:v1.0","ref":"v1.0","sha":"0ab81f3a0ab89f161da062fe0574f6edec60d5d1","user":{"login":"allegro","id":562236,"avatar_url":"https://avatars3.githubusercontent.com/u/562236?v=4","gravatar_id":"","url":"https://api.github.com/users/allegro","html_url":"https://github.com/allegro","followers_url":"https://api.github.com/users/allegro/followers","following_url":"https://api.github.com/users/allegro/following{/other_user}","gists_url":"https://api.github.com/users/allegro/gists{/gist_id}","starred_url":"https://api.github.com/users/allegro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/allegro/subscriptions","organizations_url":"https://api.github.com/users/allegro/orgs","repos_url":"https://api.github.com/users/allegro/repos","events_url":"https://api.github.com/users/allegro/events{/privacy}","received_events_url":"https://api.github.com/users/allegro/received_events","type":"Organization","site_admin":false},"repo":{"id":71782347,"name":"akubra","full_name":"allegro/akubra","owner":{"login":"allegro","id":562236,"avatar_url":"https://avatars3.githubusercontent.com/u/562236?v=4","gravatar_id":"","url":"https://api.github.com/users/allegro","html_url":"https://github.com/allegro","followers_url":"https://api.github.com/users/allegro/followers","following_url":"https://api.github.com/users/allegro/following{/other_user}","gists_url":"https://api.github.com/users/allegro/gists{/gist_id}","starred_url":"https://api.github.com/users/allegro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/allegro/subscriptions","organizations_url":"https://api.github.com/users/allegro/orgs","repos_url":"https://api.github.com/users/allegro/repos","events_url":"https://api.github.com/users/allegro/events{/privacy}","received_events_url":"https://api.github.com/users/allegro/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/allegro/akubra","description":"Simple solution to keep a independent S3 storages in sync","fork":false,"url":"https://api.github.com/repos/allegro/akubra","forks_url":"https://api.github.com/repos/allegro/akubra/forks","keys_url":"https://api.github.com/repos/allegro/akubra/keys{/key_id}","collaborators_url":"https://api.github.com/repos/allegro/akubra/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/allegro/akubra/teams","hooks_url":"https://api.github.com/repos/allegro/akubra/hooks","issue_events_url":"https://api.github.com/repos/allegro/akubra/issues/events{/number}","events_url":"https://api.github.com/repos/allegro/akubra/events","assignees_url":"https://api.github.com/repos/allegro/akubra/assignees{/user}","branches_url":"https://api.github.com/repos/allegro/akubra/branches{/branch}","tags_url":"https://api.github.com/repos/allegro/akubra/tags","blobs_url":"https://api.github.com/repos/allegro/akubra/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/allegro/akubra/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/allegro/akubra/git/refs{/sha}","trees_url":"https://api.github.com/repos/allegro/akubra/git/trees{/sha}","statuses_url":"https://api.github.com/repos/allegro/akubra/statuses/{sha}","languages_url":"https://api.github.com/repos/allegro/akubra/languages","stargazers_url":"https://api.github.com/repos/allegro/akubra/stargazers","contributors_url":"https://api.github.com/repos/allegro/akubra/contributors","subscribers_url":"https://api.github.com/repos/allegro/akubra/subscribers","subscription_url":"https://api.github.com/repos/allegro/akubra/subscription","commits_url":"https://api.github.com/repos/allegro/akubra/commits{/sha}","git_commits_url":"https://api.github.com/repos/allegro/akubra/git/commits{/sha}","comments_url":"https://api.github.com/repos/allegro/akubra/comments{/number}","issue_comment_url":"https://api.github.com/repos/allegro/akubra/issues/comments{/number}","contents_url":"https://api.github.com/repos/allegro/akubra/contents/{+path}","compare_url":"https://api.github.com/repos/allegro/akubra/compare/{base}...{head}","merges_url":"https://api.github.com/repos/allegro/akubra/merges","archive_url":"https://api.github.com/repos/allegro/akubra/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/allegro/akubra/downloads","issues_url":"https://api.github.com/repos/allegro/akubra/issues{/number}","pulls_url":"https://api.github.com/repos/allegro/akubra/pulls{/number}","milestones_url":"https://api.github.com/repos/allegro/akubra/milestones{/number}","notifications_url":"https://api.github.com/repos/allegro/akubra/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/allegro/akubra/labels{/name}","releases_url":"https://api.github.com/repos/allegro/akubra/releases{/id}","deployments_url":"https://api.github.com/repos/allegro/akubra/deployments","created_at":"2016-10-24T11:32:11Z","updated_at":"2018-04-24T21:54:35Z","pushed_at":"2018-05-16T14:26:12Z","git_url":"git://github.com/allegro/akubra.git","ssh_url":"git@github.com:allegro/akubra.git","clone_url":"https://github.com/allegro/akubra.git","svn_url":"https://github.com/allegro/akubra","homepage":"","size":8944,"stargazers_count":49,"watchers_count":49,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":4,"open_issues":6,"watchers":49,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/allegro/akubra/pulls/89"},"html":{"href":"https://github.com/allegro/akubra/pull/89"},"issue":{"href":"https://api.github.com/repos/allegro/akubra/issues/89"},"comments":{"href":"https://api.github.com/repos/allegro/akubra/issues/89/comments"},"review_comments":{"href":"https://api.github.com/repos/allegro/akubra/pulls/89/comments"},"review_comment":{"href":"https://api.github.com/repos/allegro/akubra/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/allegro/akubra/pulls/89/commits"},"statuses":{"href":"https://api.github.com/repos/allegro/akubra/statuses/02098e043e5428602275091403d7e72e025cc666"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"ksitak"}}