payload: {"action":"created","comment":{"url":"https://api.github.com/repos/vespa-engine/vespa/pulls/comments/330988903","pull_request_review_id":296804331,"id":330988903,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDMzMDk4ODkwMw==","diff_hunk":"@@ -727,24 +741,20 @@ public void deleteApplication(TenantName tenantName, ApplicationName application\n      * @throws IllegalArgumentException if the application has deployments or the caller is not authorized\n      * @throws NotExistsException if the instance does not exist\n      */\n-    public void deleteInstance(ApplicationId applicationId, Optional<Credentials> credentials) {\n-        Tenant tenant = controller.tenants().require(applicationId.tenant());\n-        if (tenant.type() != Tenant.Type.user && credentials.isEmpty())\n-                throw new IllegalArgumentException(\"Could not delete application '\" + applicationId + \"': No credentials provided\");\n-\n-        if (getInstance(applicationId).isEmpty())\n-            throw new NotExistsException(\"Could not delete application '\" + applicationId + \"': Application not found\");\n+    public void deleteInstance(ApplicationId instanceId) {\n+        if (getInstance(instanceId).isEmpty())\n+            throw new NotExistsException(\"Could not delete application '\" + instanceId + \"': Application not found\");","path":"controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java","position":233,"original_position":233,"commit_id":"9e4e78ccc79b816616680c6164050e34534fa60f","original_commit_id":"9e4e78ccc79b816616680c6164050e34534fa60f","user":{"login":"freva","id":3785505,"node_id":"MDQ6VXNlcjM3ODU1MDU=","avatar_url":"https://avatars0.githubusercontent.com/u/3785505?v=4","gravatar_id":"","url":"https://api.github.com/users/freva","html_url":"https://github.com/freva","followers_url":"https://api.github.com/users/freva/followers","following_url":"https://api.github.com/users/freva/following{/other_user}","gists_url":"https://api.github.com/users/freva/gists{/gist_id}","starred_url":"https://api.github.com/users/freva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/freva/subscriptions","organizations_url":"https://api.github.com/users/freva/orgs","repos_url":"https://api.github.com/users/freva/repos","events_url":"https://api.github.com/users/freva/events{/privacy}","received_events_url":"https://api.github.com/users/freva/received_events","type":"User","site_admin":false},"body":"```suggestion\r\n            throw new NotExistsException(\"Could not delete instance '\" + instanceId + \"': Instance not found\");\r\n```","created_at":"2019-10-03T11:24:08Z","updated_at":"2019-10-03T11:33:25Z","html_url":"https://github.com/vespa-engine/vespa/pull/10860#discussion_r330988903","pull_request_url":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/vespa-engine/vespa/pulls/comments/330988903"},"html":{"href":"https://github.com/vespa-engine/vespa/pull/10860#discussion_r330988903"},"pull_request":{"href":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860"}}},"pull_request":{"url":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860","id":324156786,"node_id":"MDExOlB1bGxSZXF1ZXN0MzI0MTU2Nzg2","html_url":"https://github.com/vespa-engine/vespa/pull/10860","diff_url":"https://github.com/vespa-engine/vespa/pull/10860.diff","patch_url":"https://github.com/vespa-engine/vespa/pull/10860.patch","issue_url":"https://api.github.com/repos/vespa-engine/vespa/issues/10860","number":10860,"state":"open","locked":false,"title":"Split instance and application and creation and deletion, but let RES…","user":{"login":"jonmv","id":7009557,"node_id":"MDQ6VXNlcjcwMDk1NTc=","avatar_url":"https://avatars3.githubusercontent.com/u/7009557?v=4","gravatar_id":"","url":"https://api.github.com/users/jonmv","html_url":"https://github.com/jonmv","followers_url":"https://api.github.com/users/jonmv/followers","following_url":"https://api.github.com/users/jonmv/following{/other_user}","gists_url":"https://api.github.com/users/jonmv/gists{/gist_id}","starred_url":"https://api.github.com/users/jonmv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonmv/subscriptions","organizations_url":"https://api.github.com/users/jonmv/orgs","repos_url":"https://api.github.com/users/jonmv/repos","events_url":"https://api.github.com/users/jonmv/events{/privacy}","received_events_url":"https://api.github.com/users/jonmv/received_events","type":"User","site_admin":false},"body":"…T API do both\r\n\r\n@freva please review.\r\n\r\nThis splits application creation and deletion, but lets the REST API do both on the instance level. The REST API also supports operations on the application level.\r\nThis also creates missing user-tenant applications, and missing instances, when attempting to start a dev deployment job. ","created_at":"2019-10-03T10:51:40Z","updated_at":"2019-10-03T11:33:24Z","closed_at":null,"merged_at":null,"merge_commit_sha":"82a7c31a8863095253845ccb2c629cf14b2f355b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860/commits","review_comments_url":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860/comments","review_comment_url":"https://api.github.com/repos/vespa-engine/vespa/pulls/comments{/number}","comments_url":"https://api.github.com/repos/vespa-engine/vespa/issues/10860/comments","statuses_url":"https://api.github.com/repos/vespa-engine/vespa/statuses/9e4e78ccc79b816616680c6164050e34534fa60f","head":{"label":"vespa-engine:jvenstad/create-instances-on-dev-deployment","ref":"jvenstad/create-instances-on-dev-deployment","sha":"9e4e78ccc79b816616680c6164050e34534fa60f","user":{"login":"vespa-engine","id":29299694,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5Mjk5Njk0","avatar_url":"https://avatars1.githubusercontent.com/u/29299694?v=4","gravatar_id":"","url":"https://api.github.com/users/vespa-engine","html_url":"https://github.com/vespa-engine","followers_url":"https://api.github.com/users/vespa-engine/followers","following_url":"https://api.github.com/users/vespa-engine/following{/other_user}","gists_url":"https://api.github.com/users/vespa-engine/gists{/gist_id}","starred_url":"https://api.github.com/users/vespa-engine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vespa-engine/subscriptions","organizations_url":"https://api.github.com/users/vespa-engine/orgs","repos_url":"https://api.github.com/users/vespa-engine/repos","events_url":"https://api.github.com/users/vespa-engine/events{/privacy}","received_events_url":"https://api.github.com/users/vespa-engine/received_events","type":"Organization","site_admin":false},"repo":{"id":60377070,"node_id":"MDEwOlJlcG9zaXRvcnk2MDM3NzA3MA==","name":"vespa","full_name":"vespa-engine/vespa","private":false,"owner":{"login":"vespa-engine","id":29299694,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5Mjk5Njk0","avatar_url":"https://avatars1.githubusercontent.com/u/29299694?v=4","gravatar_id":"","url":"https://api.github.com/users/vespa-engine","html_url":"https://github.com/vespa-engine","followers_url":"https://api.github.com/users/vespa-engine/followers","following_url":"https://api.github.com/users/vespa-engine/following{/other_user}","gists_url":"https://api.github.com/users/vespa-engine/gists{/gist_id}","starred_url":"https://api.github.com/users/vespa-engine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vespa-engine/subscriptions","organizations_url":"https://api.github.com/users/vespa-engine/orgs","repos_url":"https://api.github.com/users/vespa-engine/repos","events_url":"https://api.github.com/users/vespa-engine/events{/privacy}","received_events_url":"https://api.github.com/users/vespa-engine/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/vespa-engine/vespa","description":"Vespa is an engine for low-latency computation over large data sets.","fork":false,"url":"https://api.github.com/repos/vespa-engine/vespa","forks_url":"https://api.github.com/repos/vespa-engine/vespa/forks","keys_url":"https://api.github.com/repos/vespa-engine/vespa/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vespa-engine/vespa/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vespa-engine/vespa/teams","hooks_url":"https://api.github.com/repos/vespa-engine/vespa/hooks","issue_events_url":"https://api.github.com/repos/vespa-engine/vespa/issues/events{/number}","events_url":"https://api.github.com/repos/vespa-engine/vespa/events","assignees_url":"https://api.github.com/repos/vespa-engine/vespa/assignees{/user}","branches_url":"https://api.github.com/repos/vespa-engine/vespa/branches{/branch}","tags_url":"https://api.github.com/repos/vespa-engine/vespa/tags","blobs_url":"https://api.github.com/repos/vespa-engine/vespa/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vespa-engine/vespa/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vespa-engine/vespa/git/refs{/sha}","trees_url":"https://api.github.com/repos/vespa-engine/vespa/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vespa-engine/vespa/statuses/{sha}","languages_url":"https://api.github.com/repos/vespa-engine/vespa/languages","stargazers_url":"https://api.github.com/repos/vespa-engine/vespa/stargazers","contributors_url":"https://api.github.com/repos/vespa-engine/vespa/contributors","subscribers_url":"https://api.github.com/repos/vespa-engine/vespa/subscribers","subscription_url":"https://api.github.com/repos/vespa-engine/vespa/subscription","commits_url":"https://api.github.com/repos/vespa-engine/vespa/commits{/sha}","git_commits_url":"https://api.github.com/repos/vespa-engine/vespa/git/commits{/sha}","comments_url":"https://api.github.com/repos/vespa-engine/vespa/comments{/number}","issue_comment_url":"https://api.github.com/repos/vespa-engine/vespa/issues/comments{/number}","contents_url":"https://api.github.com/repos/vespa-engine/vespa/contents/{+path}","compare_url":"https://api.github.com/repos/vespa-engine/vespa/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vespa-engine/vespa/merges","archive_url":"https://api.github.com/repos/vespa-engine/vespa/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vespa-engine/vespa/downloads","issues_url":"https://api.github.com/repos/vespa-engine/vespa/issues{/number}","pulls_url":"https://api.github.com/repos/vespa-engine/vespa/pulls{/number}","milestones_url":"https://api.github.com/repos/vespa-engine/vespa/milestones{/number}","notifications_url":"https://api.github.com/repos/vespa-engine/vespa/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vespa-engine/vespa/labels{/name}","releases_url":"https://api.github.com/repos/vespa-engine/vespa/releases{/id}","deployments_url":"https://api.github.com/repos/vespa-engine/vespa/deployments","created_at":"2016-06-03T20:54:20Z","updated_at":"2019-10-03T10:25:23Z","pushed_at":"2019-10-03T11:29:03Z","git_url":"git://github.com/vespa-engine/vespa.git","ssh_url":"git@github.com:vespa-engine/vespa.git","clone_url":"https://github.com/vespa-engine/vespa.git","svn_url":"https://github.com/vespa-engine/vespa","homepage":"https://vespa.ai","size":100931,"stargazers_count":2946,"watchers_count":2946,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":352,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":85,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":352,"open_issues":85,"watchers":2946,"default_branch":"master"}},"base":{"label":"vespa-engine:master","ref":"master","sha":"adf22d3886ccd6de163278434a1a6d502584d0f9","user":{"login":"vespa-engine","id":29299694,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5Mjk5Njk0","avatar_url":"https://avatars1.githubusercontent.com/u/29299694?v=4","gravatar_id":"","url":"https://api.github.com/users/vespa-engine","html_url":"https://github.com/vespa-engine","followers_url":"https://api.github.com/users/vespa-engine/followers","following_url":"https://api.github.com/users/vespa-engine/following{/other_user}","gists_url":"https://api.github.com/users/vespa-engine/gists{/gist_id}","starred_url":"https://api.github.com/users/vespa-engine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vespa-engine/subscriptions","organizations_url":"https://api.github.com/users/vespa-engine/orgs","repos_url":"https://api.github.com/users/vespa-engine/repos","events_url":"https://api.github.com/users/vespa-engine/events{/privacy}","received_events_url":"https://api.github.com/users/vespa-engine/received_events","type":"Organization","site_admin":false},"repo":{"id":60377070,"node_id":"MDEwOlJlcG9zaXRvcnk2MDM3NzA3MA==","name":"vespa","full_name":"vespa-engine/vespa","private":false,"owner":{"login":"vespa-engine","id":29299694,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5Mjk5Njk0","avatar_url":"https://avatars1.githubusercontent.com/u/29299694?v=4","gravatar_id":"","url":"https://api.github.com/users/vespa-engine","html_url":"https://github.com/vespa-engine","followers_url":"https://api.github.com/users/vespa-engine/followers","following_url":"https://api.github.com/users/vespa-engine/following{/other_user}","gists_url":"https://api.github.com/users/vespa-engine/gists{/gist_id}","starred_url":"https://api.github.com/users/vespa-engine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vespa-engine/subscriptions","organizations_url":"https://api.github.com/users/vespa-engine/orgs","repos_url":"https://api.github.com/users/vespa-engine/repos","events_url":"https://api.github.com/users/vespa-engine/events{/privacy}","received_events_url":"https://api.github.com/users/vespa-engine/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/vespa-engine/vespa","description":"Vespa is an engine for low-latency computation over large data sets.","fork":false,"url":"https://api.github.com/repos/vespa-engine/vespa","forks_url":"https://api.github.com/repos/vespa-engine/vespa/forks","keys_url":"https://api.github.com/repos/vespa-engine/vespa/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vespa-engine/vespa/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vespa-engine/vespa/teams","hooks_url":"https://api.github.com/repos/vespa-engine/vespa/hooks","issue_events_url":"https://api.github.com/repos/vespa-engine/vespa/issues/events{/number}","events_url":"https://api.github.com/repos/vespa-engine/vespa/events","assignees_url":"https://api.github.com/repos/vespa-engine/vespa/assignees{/user}","branches_url":"https://api.github.com/repos/vespa-engine/vespa/branches{/branch}","tags_url":"https://api.github.com/repos/vespa-engine/vespa/tags","blobs_url":"https://api.github.com/repos/vespa-engine/vespa/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vespa-engine/vespa/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vespa-engine/vespa/git/refs{/sha}","trees_url":"https://api.github.com/repos/vespa-engine/vespa/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vespa-engine/vespa/statuses/{sha}","languages_url":"https://api.github.com/repos/vespa-engine/vespa/languages","stargazers_url":"https://api.github.com/repos/vespa-engine/vespa/stargazers","contributors_url":"https://api.github.com/repos/vespa-engine/vespa/contributors","subscribers_url":"https://api.github.com/repos/vespa-engine/vespa/subscribers","subscription_url":"https://api.github.com/repos/vespa-engine/vespa/subscription","commits_url":"https://api.github.com/repos/vespa-engine/vespa/commits{/sha}","git_commits_url":"https://api.github.com/repos/vespa-engine/vespa/git/commits{/sha}","comments_url":"https://api.github.com/repos/vespa-engine/vespa/comments{/number}","issue_comment_url":"https://api.github.com/repos/vespa-engine/vespa/issues/comments{/number}","contents_url":"https://api.github.com/repos/vespa-engine/vespa/contents/{+path}","compare_url":"https://api.github.com/repos/vespa-engine/vespa/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vespa-engine/vespa/merges","archive_url":"https://api.github.com/repos/vespa-engine/vespa/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vespa-engine/vespa/downloads","issues_url":"https://api.github.com/repos/vespa-engine/vespa/issues{/number}","pulls_url":"https://api.github.com/repos/vespa-engine/vespa/pulls{/number}","milestones_url":"https://api.github.com/repos/vespa-engine/vespa/milestones{/number}","notifications_url":"https://api.github.com/repos/vespa-engine/vespa/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vespa-engine/vespa/labels{/name}","releases_url":"https://api.github.com/repos/vespa-engine/vespa/releases{/id}","deployments_url":"https://api.github.com/repos/vespa-engine/vespa/deployments","created_at":"2016-06-03T20:54:20Z","updated_at":"2019-10-03T10:25:23Z","pushed_at":"2019-10-03T11:29:03Z","git_url":"git://github.com/vespa-engine/vespa.git","ssh_url":"git@github.com:vespa-engine/vespa.git","clone_url":"https://github.com/vespa-engine/vespa.git","svn_url":"https://github.com/vespa-engine/vespa","homepage":"https://vespa.ai","size":100931,"stargazers_count":2946,"watchers_count":2946,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":352,"mirror_url":null,"archived":false,"disabled":false,"open_issues_count":85,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":352,"open_issues":85,"watchers":2946,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860"},"html":{"href":"https://github.com/vespa-engine/vespa/pull/10860"},"issue":{"href":"https://api.github.com/repos/vespa-engine/vespa/issues/10860"},"comments":{"href":"https://api.github.com/repos/vespa-engine/vespa/issues/10860/comments"},"review_comments":{"href":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860/comments"},"review_comment":{"href":"https://api.github.com/repos/vespa-engine/vespa/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/vespa-engine/vespa/pulls/10860/commits"},"statuses":{"href":"https://api.github.com/repos/vespa-engine/vespa/statuses/9e4e78ccc79b816616680c6164050e34534fa60f"}},"author_association":"CONTRIBUTOR"}}
other: {"actor":{"display_login":"freva"}}