{"action":"created","comment":{"url":"https://api.github.com/repos/zalando/zmon-controller/pulls/comments/50666775","id":50666775,"diff_hunk":"@@ -39,6 +39,14 @@ public CheckDefinition createOrUpdate(@Valid\n         return zMonService.createOrUpdateCheckDefinition(checkDefinition);\n     }\n \n+    @RequestMapping(method = RequestMethod.DELETE)\n+    @ResponseStatus(HttpStatus.OK)\n+    public void deleteCheckDef(@Valid @RequestBody(required = true)\n+            final CheckDefinitionImport checkDefinition) throws ZMonException {","path":"zmon-controller-app/src/main/java/de/zalando/zmon/rest/CheckDefinitionsApi.java","position":7,"original_position":7,"commit_id":"79d0a6b3098de932528308c7f0f415f5f55aaad8","original_commit_id":"79d0a6b3098de932528308c7f0f415f5f55aaad8","user":{"login":"hjacobs","id":510328,"avatar_url":"https://avatars.githubusercontent.com/u/510328?v=3","gravatar_id":"","url":"https://api.github.com/users/hjacobs","html_url":"https://github.com/hjacobs","followers_url":"https://api.github.com/users/hjacobs/followers","following_url":"https://api.github.com/users/hjacobs/following{/other_user}","gists_url":"https://api.github.com/users/hjacobs/gists{/gist_id}","starred_url":"https://api.github.com/users/hjacobs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hjacobs/subscriptions","organizations_url":"https://api.github.com/users/hjacobs/orgs","repos_url":"https://api.github.com/users/hjacobs/repos","events_url":"https://api.github.com/users/hjacobs/events{/privacy}","received_events_url":"https://api.github.com/users/hjacobs/received_events","type":"User","site_admin":false},"body":"shouldn't this only take an ID parameter instead of a complete body?","created_at":"2016-01-25T08:52:31Z","updated_at":"2016-01-25T08:52:31Z","html_url":"https://github.com/zalando/zmon-controller/pull/22#discussion_r50666775","pull_request_url":"https://api.github.com/repos/zalando/zmon-controller/pulls/22","_links":{"self":{"href":"https://api.github.com/repos/zalando/zmon-controller/pulls/comments/50666775"},"html":{"href":"https://github.com/zalando/zmon-controller/pull/22#discussion_r50666775"},"pull_request":{"href":"https://api.github.com/repos/zalando/zmon-controller/pulls/22"}}},"pull_request":{"url":"https://api.github.com/repos/zalando/zmon-controller/pulls/22","id":57006504,"html_url":"https://github.com/zalando/zmon-controller/pull/22","diff_url":"https://github.com/zalando/zmon-controller/pull/22.diff","patch_url":"https://github.com/zalando/zmon-controller/pull/22.patch","issue_url":"https://api.github.com/repos/zalando/zmon-controller/issues/22","number":22,"state":"open","locked":false,"title":"Check definition removal via REST API","user":{"login":"bocytko","id":711379,"avatar_url":"https://avatars.githubusercontent.com/u/711379?v=3","gravatar_id":"","url":"https://api.github.com/users/bocytko","html_url":"https://github.com/bocytko","followers_url":"https://api.github.com/users/bocytko/followers","following_url":"https://api.github.com/users/bocytko/following{/other_user}","gists_url":"https://api.github.com/users/bocytko/gists{/gist_id}","starred_url":"https://api.github.com/users/bocytko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bocytko/subscriptions","organizations_url":"https://api.github.com/users/bocytko/orgs","repos_url":"https://api.github.com/users/bocytko/repos","events_url":"https://api.github.com/users/bocytko/events{/privacy}","received_events_url":"https://api.github.com/users/bocytko/received_events","type":"User","site_admin":false},"body":"@Jan-M as far as I understood the code correctly, this should be enough for supporting check definition removal. The entries are marked as \"DELETED\" in the DB and will be cleaned up completely as soon as the alerts are removed as well. The scheduler fetches only active check definitions, so it should also detect the removal correctly. If I missed sth. please let me know.","created_at":"2016-01-24T16:04:05Z","updated_at":"2016-01-25T08:52:31Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d9c36f8c171af531679621aa3231c710d2420f31","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/zalando/zmon-controller/pulls/22/commits","review_comments_url":"https://api.github.com/repos/zalando/zmon-controller/pulls/22/comments","review_comment_url":"https://api.github.com/repos/zalando/zmon-controller/pulls/comments{/number}","comments_url":"https://api.github.com/repos/zalando/zmon-controller/issues/22/comments","statuses_url":"https://api.github.com/repos/zalando/zmon-controller/statuses/79d0a6b3098de932528308c7f0f415f5f55aaad8","head":{"label":"bocytko:feature/check-definition-removal-via-rest-api","ref":"feature/check-definition-removal-via-rest-api","sha":"79d0a6b3098de932528308c7f0f415f5f55aaad8","user":{"login":"bocytko","id":711379,"avatar_url":"https://avatars.githubusercontent.com/u/711379?v=3","gravatar_id":"","url":"https://api.github.com/users/bocytko","html_url":"https://github.com/bocytko","followers_url":"https://api.github.com/users/bocytko/followers","following_url":"https://api.github.com/users/bocytko/following{/other_user}","gists_url":"https://api.github.com/users/bocytko/gists{/gist_id}","starred_url":"https://api.github.com/users/bocytko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bocytko/subscriptions","organizations_url":"https://api.github.com/users/bocytko/orgs","repos_url":"https://api.github.com/users/bocytko/repos","events_url":"https://api.github.com/users/bocytko/events{/privacy}","received_events_url":"https://api.github.com/users/bocytko/received_events","type":"User","site_admin":false},"repo":{"id":50247755,"name":"zmon-controller","full_name":"bocytko/zmon-controller","owner":{"login":"bocytko","id":711379,"avatar_url":"https://avatars.githubusercontent.com/u/711379?v=3","gravatar_id":"","url":"https://api.github.com/users/bocytko","html_url":"https://github.com/bocytko","followers_url":"https://api.github.com/users/bocytko/followers","following_url":"https://api.github.com/users/bocytko/following{/other_user}","gists_url":"https://api.github.com/users/bocytko/gists{/gist_id}","starred_url":"https://api.github.com/users/bocytko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bocytko/subscriptions","organizations_url":"https://api.github.com/users/bocytko/orgs","repos_url":"https://api.github.com/users/bocytko/repos","events_url":"https://api.github.com/users/bocytko/events{/privacy}","received_events_url":"https://api.github.com/users/bocytko/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bocytko/zmon-controller","description":"ZMON Frontend Controller","fork":true,"url":"https://api.github.com/repos/bocytko/zmon-controller","forks_url":"https://api.github.com/repos/bocytko/zmon-controller/forks","keys_url":"https://api.github.com/repos/bocytko/zmon-controller/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bocytko/zmon-controller/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bocytko/zmon-controller/teams","hooks_url":"https://api.github.com/repos/bocytko/zmon-controller/hooks","issue_events_url":"https://api.github.com/repos/bocytko/zmon-controller/issues/events{/number}","events_url":"https://api.github.com/repos/bocytko/zmon-controller/events","assignees_url":"https://api.github.com/repos/bocytko/zmon-controller/assignees{/user}","branches_url":"https://api.github.com/repos/bocytko/zmon-controller/branches{/branch}","tags_url":"https://api.github.com/repos/bocytko/zmon-controller/tags","blobs_url":"https://api.github.com/repos/bocytko/zmon-controller/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bocytko/zmon-controller/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bocytko/zmon-controller/git/refs{/sha}","trees_url":"https://api.github.com/repos/bocytko/zmon-controller/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bocytko/zmon-controller/statuses/{sha}","languages_url":"https://api.github.com/repos/bocytko/zmon-controller/languages","stargazers_url":"https://api.github.com/repos/bocytko/zmon-controller/stargazers","contributors_url":"https://api.github.com/repos/bocytko/zmon-controller/contributors","subscribers_url":"https://api.github.com/repos/bocytko/zmon-controller/subscribers","subscription_url":"https://api.github.com/repos/bocytko/zmon-controller/subscription","commits_url":"https://api.github.com/repos/bocytko/zmon-controller/commits{/sha}","git_commits_url":"https://api.github.com/repos/bocytko/zmon-controller/git/commits{/sha}","comments_url":"https://api.github.com/repos/bocytko/zmon-controller/comments{/number}","issue_comment_url":"https://api.github.com/repos/bocytko/zmon-controller/issues/comments{/number}","contents_url":"https://api.github.com/repos/bocytko/zmon-controller/contents/{+path}","compare_url":"https://api.github.com/repos/bocytko/zmon-controller/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bocytko/zmon-controller/merges","archive_url":"https://api.github.com/repos/bocytko/zmon-controller/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bocytko/zmon-controller/downloads","issues_url":"https://api.github.com/repos/bocytko/zmon-controller/issues{/number}","pulls_url":"https://api.github.com/repos/bocytko/zmon-controller/pulls{/number}","milestones_url":"https://api.github.com/repos/bocytko/zmon-controller/milestones{/number}","notifications_url":"https://api.github.com/repos/bocytko/zmon-controller/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bocytko/zmon-controller/labels{/name}","releases_url":"https://api.github.com/repos/bocytko/zmon-controller/releases{/id}","deployments_url":"https://api.github.com/repos/bocytko/zmon-controller/deployments","created_at":"2016-01-23T16:50:28Z","updated_at":"2016-01-23T16:50:31Z","pushed_at":"2016-01-24T16:39:13Z","git_url":"git://github.com/bocytko/zmon-controller.git","ssh_url":"git@github.com:bocytko/zmon-controller.git","clone_url":"https://github.com/bocytko/zmon-controller.git","svn_url":"https://github.com/bocytko/zmon-controller","homepage":"http://zmon.readthedocs.org/","size":79927,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"zalando:master","ref":"master","sha":"02445653e1867a617b2ac0f9469feaa0c743e5f1","user":{"login":"zalando","id":1564818,"avatar_url":"https://avatars.githubusercontent.com/u/1564818?v=3","gravatar_id":"","url":"https://api.github.com/users/zalando","html_url":"https://github.com/zalando","followers_url":"https://api.github.com/users/zalando/followers","following_url":"https://api.github.com/users/zalando/following{/other_user}","gists_url":"https://api.github.com/users/zalando/gists{/gist_id}","starred_url":"https://api.github.com/users/zalando/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zalando/subscriptions","organizations_url":"https://api.github.com/users/zalando/orgs","repos_url":"https://api.github.com/users/zalando/repos","events_url":"https://api.github.com/users/zalando/events{/privacy}","received_events_url":"https://api.github.com/users/zalando/received_events","type":"Organization","site_admin":false},"repo":{"id":28918422,"name":"zmon-controller","full_name":"zalando/zmon-controller","owner":{"login":"zalando","id":1564818,"avatar_url":"https://avatars.githubusercontent.com/u/1564818?v=3","gravatar_id":"","url":"https://api.github.com/users/zalando","html_url":"https://github.com/zalando","followers_url":"https://api.github.com/users/zalando/followers","following_url":"https://api.github.com/users/zalando/following{/other_user}","gists_url":"https://api.github.com/users/zalando/gists{/gist_id}","starred_url":"https://api.github.com/users/zalando/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zalando/subscriptions","organizations_url":"https://api.github.com/users/zalando/orgs","repos_url":"https://api.github.com/users/zalando/repos","events_url":"https://api.github.com/users/zalando/events{/privacy}","received_events_url":"https://api.github.com/users/zalando/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/zalando/zmon-controller","description":"ZMON Frontend Controller","fork":false,"url":"https://api.github.com/repos/zalando/zmon-controller","forks_url":"https://api.github.com/repos/zalando/zmon-controller/forks","keys_url":"https://api.github.com/repos/zalando/zmon-controller/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zalando/zmon-controller/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zalando/zmon-controller/teams","hooks_url":"https://api.github.com/repos/zalando/zmon-controller/hooks","issue_events_url":"https://api.github.com/repos/zalando/zmon-controller/issues/events{/number}","events_url":"https://api.github.com/repos/zalando/zmon-controller/events","assignees_url":"https://api.github.com/repos/zalando/zmon-controller/assignees{/user}","branches_url":"https://api.github.com/repos/zalando/zmon-controller/branches{/branch}","tags_url":"https://api.github.com/repos/zalando/zmon-controller/tags","blobs_url":"https://api.github.com/repos/zalando/zmon-controller/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zalando/zmon-controller/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zalando/zmon-controller/git/refs{/sha}","trees_url":"https://api.github.com/repos/zalando/zmon-controller/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zalando/zmon-controller/statuses/{sha}","languages_url":"https://api.github.com/repos/zalando/zmon-controller/languages","stargazers_url":"https://api.github.com/repos/zalando/zmon-controller/stargazers","contributors_url":"https://api.github.com/repos/zalando/zmon-controller/contributors","subscribers_url":"https://api.github.com/repos/zalando/zmon-controller/subscribers","subscription_url":"https://api.github.com/repos/zalando/zmon-controller/subscription","commits_url":"https://api.github.com/repos/zalando/zmon-controller/commits{/sha}","git_commits_url":"https://api.github.com/repos/zalando/zmon-controller/git/commits{/sha}","comments_url":"https://api.github.com/repos/zalando/zmon-controller/comments{/number}","issue_comment_url":"https://api.github.com/repos/zalando/zmon-controller/issues/comments{/number}","contents_url":"https://api.github.com/repos/zalando/zmon-controller/contents/{+path}","compare_url":"https://api.github.com/repos/zalando/zmon-controller/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zalando/zmon-controller/merges","archive_url":"https://api.github.com/repos/zalando/zmon-controller/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zalando/zmon-controller/downloads","issues_url":"https://api.github.com/repos/zalando/zmon-controller/issues{/number}","pulls_url":"https://api.github.com/repos/zalando/zmon-controller/pulls{/number}","milestones_url":"https://api.github.com/repos/zalando/zmon-controller/milestones{/number}","notifications_url":"https://api.github.com/repos/zalando/zmon-controller/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zalando/zmon-controller/labels{/name}","releases_url":"https://api.github.com/repos/zalando/zmon-controller/releases{/id}","deployments_url":"https://api.github.com/repos/zalando/zmon-controller/deployments","created_at":"2015-01-07T14:42:48Z","updated_at":"2016-01-13T10:35:54Z","pushed_at":"2016-01-24T16:39:13Z","git_url":"git://github.com/zalando/zmon-controller.git","ssh_url":"git@github.com:zalando/zmon-controller.git","clone_url":"https://github.com/zalando/zmon-controller.git","svn_url":"https://github.com/zalando/zmon-controller","homepage":"http://zmon.readthedocs.org/","size":79949,"stargazers_count":7,"watchers_count":7,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":11,"forks":2,"open_issues":11,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/zalando/zmon-controller/pulls/22"},"html":{"href":"https://github.com/zalando/zmon-controller/pull/22"},"issue":{"href":"https://api.github.com/repos/zalando/zmon-controller/issues/22"},"comments":{"href":"https://api.github.com/repos/zalando/zmon-controller/issues/22/comments"},"review_comments":{"href":"https://api.github.com/repos/zalando/zmon-controller/pulls/22/comments"},"review_comment":{"href":"https://api.github.com/repos/zalando/zmon-controller/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/zalando/zmon-controller/pulls/22/commits"},"statuses":{"href":"https://api.github.com/repos/zalando/zmon-controller/statuses/79d0a6b3098de932528308c7f0f415f5f55aaad8"}}}}