{"action":"closed","number":11,"pull_request":{"url":"https://api.github.com/repos/cloudflare/complainer/pulls/11","id":73081838,"html_url":"https://github.com/cloudflare/complainer/pull/11","diff_url":"https://github.com/cloudflare/complainer/pull/11.diff","patch_url":"https://github.com/cloudflare/complainer/pull/11.patch","issue_url":"https://api.github.com/repos/cloudflare/complainer/issues/11","number":11,"state":"closed","locked":false,"title":"Added Slack reporter","user":{"login":"andygrunwald","id":320064,"avatar_url":"https://avatars.githubusercontent.com/u/320064?v=3","gravatar_id":"","url":"https://api.github.com/users/andygrunwald","html_url":"https://github.com/andygrunwald","followers_url":"https://api.github.com/users/andygrunwald/followers","following_url":"https://api.github.com/users/andygrunwald/following{/other_user}","gists_url":"https://api.github.com/users/andygrunwald/gists{/gist_id}","starred_url":"https://api.github.com/users/andygrunwald/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andygrunwald/subscriptions","organizations_url":"https://api.github.com/users/andygrunwald/orgs","repos_url":"https://api.github.com/users/andygrunwald/repos","events_url":"https://api.github.com/users/andygrunwald/events{/privacy}","received_events_url":"https://api.github.com/users/andygrunwald/received_events","type":"User","site_admin":false},"body":"As an alternative to the hipchat reporter, this PR offers a slack reporter.\r\nThe implementation was done accordingly the [Incoming Webhooks @ Slack API docs](https://api.slack.com/incoming-webhooks).\r\n\r\nI tested the complete env with a Slack installation and the docker mesos cluster x and a dummy chronos job:\r\n```\r\necho \"hallo\" && sleep 20 && echo \"bye bye\" && exit 2\r\n```\r\n\r\nStart the complainer + Logs of first failures:\r\n```\r\n$ ./complainer -masters \"http://192.168.99.100:5050\" \\\r\n                     -reporters \"slack\" \\\r\n                     -slack.channel \"#mesos\" \\\r\n                     -slack.hook_url \"https://hooks.slack.com/services/TOKEN\" \\\r\n                     -slack.username \"Mesos Cluster\" \\\r\n                     -slack.icon_emoji \":mesos:\" \\\r\n                     -uploader \"noop\"\r\n2016/06/08 18:35:57 Reporting ChronosTask:my-failing-job (ct:1465403728460:1:my-failing-job:) from 192.168.99.100\r\n2016/06/08 18:36:23 Reporting ChronosTask:my-failing-job (ct:1465403759309:0:my-failing-job:) from 192.168.99.100\r\n```\r\n\r\nHere is how such a message will look like in Slack:\r\n<img width=\"823\" alt=\"screen shot 2016-06-08 at 18 49 00\" src=\"https://cloud.githubusercontent.com/assets/320064/15902723/b483bf62-2da9-11e6-8530-a86a60c1c6aa.png\">\r\n","created_at":"2016-06-08T16:49:38Z","updated_at":"2016-06-09T11:25:20Z","closed_at":"2016-06-09T11:25:20Z","merged_at":"2016-06-09T11:25:20Z","merge_commit_sha":"d1111b6207645d71576683a9b0c3c9b82d8c6909","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/cloudflare/complainer/pulls/11/commits","review_comments_url":"https://api.github.com/repos/cloudflare/complainer/pulls/11/comments","review_comment_url":"https://api.github.com/repos/cloudflare/complainer/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cloudflare/complainer/issues/11/comments","statuses_url":"https://api.github.com/repos/cloudflare/complainer/statuses/f7761d4219758e056c2b4d8f4e9120850da5deb1","head":{"label":"andygrunwald:slack-reporter","ref":"slack-reporter","sha":"f7761d4219758e056c2b4d8f4e9120850da5deb1","user":{"login":"andygrunwald","id":320064,"avatar_url":"https://avatars.githubusercontent.com/u/320064?v=3","gravatar_id":"","url":"https://api.github.com/users/andygrunwald","html_url":"https://github.com/andygrunwald","followers_url":"https://api.github.com/users/andygrunwald/followers","following_url":"https://api.github.com/users/andygrunwald/following{/other_user}","gists_url":"https://api.github.com/users/andygrunwald/gists{/gist_id}","starred_url":"https://api.github.com/users/andygrunwald/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andygrunwald/subscriptions","organizations_url":"https://api.github.com/users/andygrunwald/orgs","repos_url":"https://api.github.com/users/andygrunwald/repos","events_url":"https://api.github.com/users/andygrunwald/events{/privacy}","received_events_url":"https://api.github.com/users/andygrunwald/received_events","type":"User","site_admin":false},"repo":{"id":60701120,"name":"complainer","full_name":"andygrunwald/complainer","owner":{"login":"andygrunwald","id":320064,"avatar_url":"https://avatars.githubusercontent.com/u/320064?v=3","gravatar_id":"","url":"https://api.github.com/users/andygrunwald","html_url":"https://github.com/andygrunwald","followers_url":"https://api.github.com/users/andygrunwald/followers","following_url":"https://api.github.com/users/andygrunwald/following{/other_user}","gists_url":"https://api.github.com/users/andygrunwald/gists{/gist_id}","starred_url":"https://api.github.com/users/andygrunwald/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andygrunwald/subscriptions","organizations_url":"https://api.github.com/users/andygrunwald/orgs","repos_url":"https://api.github.com/users/andygrunwald/repos","events_url":"https://api.github.com/users/andygrunwald/events{/privacy}","received_events_url":"https://api.github.com/users/andygrunwald/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/andygrunwald/complainer","description":" Complainer's job is to send notifications to different services when tasks fail on Mesos cluster.","fork":true,"url":"https://api.github.com/repos/andygrunwald/complainer","forks_url":"https://api.github.com/repos/andygrunwald/complainer/forks","keys_url":"https://api.github.com/repos/andygrunwald/complainer/keys{/key_id}","collaborators_url":"https://api.github.com/repos/andygrunwald/complainer/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/andygrunwald/complainer/teams","hooks_url":"https://api.github.com/repos/andygrunwald/complainer/hooks","issue_events_url":"https://api.github.com/repos/andygrunwald/complainer/issues/events{/number}","events_url":"https://api.github.com/repos/andygrunwald/complainer/events","assignees_url":"https://api.github.com/repos/andygrunwald/complainer/assignees{/user}","branches_url":"https://api.github.com/repos/andygrunwald/complainer/branches{/branch}","tags_url":"https://api.github.com/repos/andygrunwald/complainer/tags","blobs_url":"https://api.github.com/repos/andygrunwald/complainer/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/andygrunwald/complainer/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/andygrunwald/complainer/git/refs{/sha}","trees_url":"https://api.github.com/repos/andygrunwald/complainer/git/trees{/sha}","statuses_url":"https://api.github.com/repos/andygrunwald/complainer/statuses/{sha}","languages_url":"https://api.github.com/repos/andygrunwald/complainer/languages","stargazers_url":"https://api.github.com/repos/andygrunwald/complainer/stargazers","contributors_url":"https://api.github.com/repos/andygrunwald/complainer/contributors","subscribers_url":"https://api.github.com/repos/andygrunwald/complainer/subscribers","subscription_url":"https://api.github.com/repos/andygrunwald/complainer/subscription","commits_url":"https://api.github.com/repos/andygrunwald/complainer/commits{/sha}","git_commits_url":"https://api.github.com/repos/andygrunwald/complainer/git/commits{/sha}","comments_url":"https://api.github.com/repos/andygrunwald/complainer/comments{/number}","issue_comment_url":"https://api.github.com/repos/andygrunwald/complainer/issues/comments{/number}","contents_url":"https://api.github.com/repos/andygrunwald/complainer/contents/{+path}","compare_url":"https://api.github.com/repos/andygrunwald/complainer/compare/{base}...{head}","merges_url":"https://api.github.com/repos/andygrunwald/complainer/merges","archive_url":"https://api.github.com/repos/andygrunwald/complainer/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/andygrunwald/complainer/downloads","issues_url":"https://api.github.com/repos/andygrunwald/complainer/issues{/number}","pulls_url":"https://api.github.com/repos/andygrunwald/complainer/pulls{/number}","milestones_url":"https://api.github.com/repos/andygrunwald/complainer/milestones{/number}","notifications_url":"https://api.github.com/repos/andygrunwald/complainer/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/andygrunwald/complainer/labels{/name}","releases_url":"https://api.github.com/repos/andygrunwald/complainer/releases{/id}","deployments_url":"https://api.github.com/repos/andygrunwald/complainer/deployments","created_at":"2016-06-08T13:45:42Z","updated_at":"2016-06-08T13:45:43Z","pushed_at":"2016-06-09T11:21:24Z","git_url":"git://github.com/andygrunwald/complainer.git","ssh_url":"git@github.com:andygrunwald/complainer.git","clone_url":"https://github.com/andygrunwald/complainer.git","svn_url":"https://github.com/andygrunwald/complainer","homepage":"","size":663,"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":"cloudflare:master","ref":"master","sha":"ebaf09af8372e07566451152cc3093c0a4b4ebdf","user":{"login":"cloudflare","id":314135,"avatar_url":"https://avatars.githubusercontent.com/u/314135?v=3","gravatar_id":"","url":"https://api.github.com/users/cloudflare","html_url":"https://github.com/cloudflare","followers_url":"https://api.github.com/users/cloudflare/followers","following_url":"https://api.github.com/users/cloudflare/following{/other_user}","gists_url":"https://api.github.com/users/cloudflare/gists{/gist_id}","starred_url":"https://api.github.com/users/cloudflare/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cloudflare/subscriptions","organizations_url":"https://api.github.com/users/cloudflare/orgs","repos_url":"https://api.github.com/users/cloudflare/repos","events_url":"https://api.github.com/users/cloudflare/events{/privacy}","received_events_url":"https://api.github.com/users/cloudflare/received_events","type":"Organization","site_admin":false},"repo":{"id":59307531,"name":"complainer","full_name":"cloudflare/complainer","owner":{"login":"cloudflare","id":314135,"avatar_url":"https://avatars.githubusercontent.com/u/314135?v=3","gravatar_id":"","url":"https://api.github.com/users/cloudflare","html_url":"https://github.com/cloudflare","followers_url":"https://api.github.com/users/cloudflare/followers","following_url":"https://api.github.com/users/cloudflare/following{/other_user}","gists_url":"https://api.github.com/users/cloudflare/gists{/gist_id}","starred_url":"https://api.github.com/users/cloudflare/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cloudflare/subscriptions","organizations_url":"https://api.github.com/users/cloudflare/orgs","repos_url":"https://api.github.com/users/cloudflare/repos","events_url":"https://api.github.com/users/cloudflare/events{/privacy}","received_events_url":"https://api.github.com/users/cloudflare/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cloudflare/complainer","description":" Complainer's job is to send notifications to different services when tasks fail on Mesos cluster.","fork":false,"url":"https://api.github.com/repos/cloudflare/complainer","forks_url":"https://api.github.com/repos/cloudflare/complainer/forks","keys_url":"https://api.github.com/repos/cloudflare/complainer/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cloudflare/complainer/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cloudflare/complainer/teams","hooks_url":"https://api.github.com/repos/cloudflare/complainer/hooks","issue_events_url":"https://api.github.com/repos/cloudflare/complainer/issues/events{/number}","events_url":"https://api.github.com/repos/cloudflare/complainer/events","assignees_url":"https://api.github.com/repos/cloudflare/complainer/assignees{/user}","branches_url":"https://api.github.com/repos/cloudflare/complainer/branches{/branch}","tags_url":"https://api.github.com/repos/cloudflare/complainer/tags","blobs_url":"https://api.github.com/repos/cloudflare/complainer/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cloudflare/complainer/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cloudflare/complainer/git/refs{/sha}","trees_url":"https://api.github.com/repos/cloudflare/complainer/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cloudflare/complainer/statuses/{sha}","languages_url":"https://api.github.com/repos/cloudflare/complainer/languages","stargazers_url":"https://api.github.com/repos/cloudflare/complainer/stargazers","contributors_url":"https://api.github.com/repos/cloudflare/complainer/contributors","subscribers_url":"https://api.github.com/repos/cloudflare/complainer/subscribers","subscription_url":"https://api.github.com/repos/cloudflare/complainer/subscription","commits_url":"https://api.github.com/repos/cloudflare/complainer/commits{/sha}","git_commits_url":"https://api.github.com/repos/cloudflare/complainer/git/commits{/sha}","comments_url":"https://api.github.com/repos/cloudflare/complainer/comments{/number}","issue_comment_url":"https://api.github.com/repos/cloudflare/complainer/issues/comments{/number}","contents_url":"https://api.github.com/repos/cloudflare/complainer/contents/{+path}","compare_url":"https://api.github.com/repos/cloudflare/complainer/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cloudflare/complainer/merges","archive_url":"https://api.github.com/repos/cloudflare/complainer/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cloudflare/complainer/downloads","issues_url":"https://api.github.com/repos/cloudflare/complainer/issues{/number}","pulls_url":"https://api.github.com/repos/cloudflare/complainer/pulls{/number}","milestones_url":"https://api.github.com/repos/cloudflare/complainer/milestones{/number}","notifications_url":"https://api.github.com/repos/cloudflare/complainer/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cloudflare/complainer/labels{/name}","releases_url":"https://api.github.com/repos/cloudflare/complainer/releases{/id}","deployments_url":"https://api.github.com/repos/cloudflare/complainer/deployments","created_at":"2016-05-20T15:58:14Z","updated_at":"2016-06-07T07:19:33Z","pushed_at":"2016-06-09T11:25:20Z","git_url":"git://github.com/cloudflare/complainer.git","ssh_url":"git@github.com:cloudflare/complainer.git","clone_url":"https://github.com/cloudflare/complainer.git","svn_url":"https://github.com/cloudflare/complainer","homepage":"","size":656,"stargazers_count":25,"watchers_count":25,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":2,"forks":3,"open_issues":2,"watchers":25,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cloudflare/complainer/pulls/11"},"html":{"href":"https://github.com/cloudflare/complainer/pull/11"},"issue":{"href":"https://api.github.com/repos/cloudflare/complainer/issues/11"},"comments":{"href":"https://api.github.com/repos/cloudflare/complainer/issues/11/comments"},"review_comments":{"href":"https://api.github.com/repos/cloudflare/complainer/pulls/11/comments"},"review_comment":{"href":"https://api.github.com/repos/cloudflare/complainer/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cloudflare/complainer/pulls/11/commits"},"statuses":{"href":"https://api.github.com/repos/cloudflare/complainer/statuses/f7761d4219758e056c2b4d8f4e9120850da5deb1"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"bobrik","id":89186,"avatar_url":"https://avatars.githubusercontent.com/u/89186?v=3","gravatar_id":"","url":"https://api.github.com/users/bobrik","html_url":"https://github.com/bobrik","followers_url":"https://api.github.com/users/bobrik/followers","following_url":"https://api.github.com/users/bobrik/following{/other_user}","gists_url":"https://api.github.com/users/bobrik/gists{/gist_id}","starred_url":"https://api.github.com/users/bobrik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bobrik/subscriptions","organizations_url":"https://api.github.com/users/bobrik/orgs","repos_url":"https://api.github.com/users/bobrik/repos","events_url":"https://api.github.com/users/bobrik/events{/privacy}","received_events_url":"https://api.github.com/users/bobrik/received_events","type":"User","site_admin":false},"comments":7,"review_comments":8,"commits":1,"additions":171,"deletions":1,"changed_files":3}}
{"actor":{"display_login":"bobrik"}}