{"action":"created","comment":{"url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/comments/231826200","pull_request_review_id":172880459,"id":231826200,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMTgyNjIwMA==","diff_hunk":"@@ -136,6 +141,50 @@ class DashboardController extends FabrikBaseController {\n       .throw(new ContinueWithNext());\n   }\n \n+  validateServiceInstanceAndType(req, res) {\n+    /* jshint unused:false */\n+    const instance_id = req.params.instance_id;\n+    const instance_type = req.params.instance_type;\n+    return this._getApiServerResource(instance_id, instance_type)\n+      .then(resource => _.get(resource, 'spec.options'))\n+      .then(resourceOptions => {\n+        const service_id = _.get(resourceOptions, 'service_id');\n+        const plan_id = _.get(resourceOptions, 'plan_id');\n+        const context = _.get(resourceOptions, 'context');\n+        req.params.service_id = service_id;\n+        req.params.plan_id = plan_id;\n+        return this.fabrik.createInstance(instance_id, service_id, plan_id, context);\n+      })\n+      .then(instance => {\n+        req.instance = instance;\n+        req.manager = instance.manager;\n+      })\n+      .throw(new ContinueWithNext());\n+  }\n+\n+  _getApiServerResource(instance_id, instance_type) {","path":"api-controllers/DashboardController.js","position":46,"original_position":46,"commit_id":"190b7fab1bcbac3a06f8f75eafc1df010966fca6","original_commit_id":"190b7fab1bcbac3a06f8f75eafc1df010966fca6","user":{"login":"kamath-prasad","id":28445395,"node_id":"MDQ6VXNlcjI4NDQ1Mzk1","avatar_url":"https://avatars1.githubusercontent.com/u/28445395?v=4","gravatar_id":"","url":"https://api.github.com/users/kamath-prasad","html_url":"https://github.com/kamath-prasad","followers_url":"https://api.github.com/users/kamath-prasad/followers","following_url":"https://api.github.com/users/kamath-prasad/following{/other_user}","gists_url":"https://api.github.com/users/kamath-prasad/gists{/gist_id}","starred_url":"https://api.github.com/users/kamath-prasad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kamath-prasad/subscriptions","organizations_url":"https://api.github.com/users/kamath-prasad/orgs","repos_url":"https://api.github.com/users/kamath-prasad/repos","events_url":"https://api.github.com/users/kamath-prasad/events{/privacy}","received_events_url":"https://api.github.com/users/kamath-prasad/received_events","type":"User","site_admin":false},"body":"ok , got it.","created_at":"2018-11-08T10:02:00Z","updated_at":"2018-11-08T10:02:00Z","html_url":"https://github.com/cloudfoundry-incubator/service-fabrik-broker/pull/441#discussion_r231826200","pull_request_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/comments/231826200"},"html":{"href":"https://github.com/cloudfoundry-incubator/service-fabrik-broker/pull/441#discussion_r231826200"},"pull_request":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441"}},"in_reply_to_id":231795503},"pull_request":{"url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441","id":224620969,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI0NjIwOTY5","html_url":"https://github.com/cloudfoundry-incubator/service-fabrik-broker/pull/441","diff_url":"https://github.com/cloudfoundry-incubator/service-fabrik-broker/pull/441.diff","patch_url":"https://github.com/cloudfoundry-incubator/service-fabrik-broker/pull/441.patch","issue_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/issues/441","number":441,"state":"open","locked":false,"title":"Dashboard url would be updated with new plan in patch api response","user":{"login":"sauravmndl","id":17878349,"node_id":"MDQ6VXNlcjE3ODc4MzQ5","avatar_url":"https://avatars2.githubusercontent.com/u/17878349?v=4","gravatar_id":"","url":"https://api.github.com/users/sauravmndl","html_url":"https://github.com/sauravmndl","followers_url":"https://api.github.com/users/sauravmndl/followers","following_url":"https://api.github.com/users/sauravmndl/following{/other_user}","gists_url":"https://api.github.com/users/sauravmndl/gists{/gist_id}","starred_url":"https://api.github.com/users/sauravmndl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sauravmndl/subscriptions","organizations_url":"https://api.github.com/users/sauravmndl/orgs","repos_url":"https://api.github.com/users/sauravmndl/repos","events_url":"https://api.github.com/users/sauravmndl/events{/privacy}","received_events_url":"https://api.github.com/users/sauravmndl/received_events","type":"User","site_admin":false},"body":"Dashboard url according to osb api spec is also part of response body in PATCH request. So, when update of service instance is done with new plan, the **dashboard_url** is also updated in response body.\r\nAlso format of the dashboard is changed and old dashboard support is sustained in parallel. Idea to make internal methods platform agnostic.","created_at":"2018-10-22T08:51:56Z","updated_at":"2018-11-08T10:02:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a838f10d2ef1fe0c1b6aa34db1f99a4ffeaf50a5","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":697815615,"node_id":"MDU6TGFiZWw2OTc4MTU2MTU=","url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/labels/DO%20NOT%20MERGE","name":"DO NOT MERGE","color":"b60205","default":false},{"id":776019882,"node_id":"MDU6TGFiZWw3NzYwMTk4ODI=","url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/labels/unscheduled","name":"unscheduled","color":"D9D9D9","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441/commits","review_comments_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441/comments","review_comment_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/issues/441/comments","statuses_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/statuses/190b7fab1bcbac3a06f8f75eafc1df010966fca6","head":{"label":"sauravmndl:update-dashboard","ref":"update-dashboard","sha":"190b7fab1bcbac3a06f8f75eafc1df010966fca6","user":{"login":"sauravmndl","id":17878349,"node_id":"MDQ6VXNlcjE3ODc4MzQ5","avatar_url":"https://avatars2.githubusercontent.com/u/17878349?v=4","gravatar_id":"","url":"https://api.github.com/users/sauravmndl","html_url":"https://github.com/sauravmndl","followers_url":"https://api.github.com/users/sauravmndl/followers","following_url":"https://api.github.com/users/sauravmndl/following{/other_user}","gists_url":"https://api.github.com/users/sauravmndl/gists{/gist_id}","starred_url":"https://api.github.com/users/sauravmndl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sauravmndl/subscriptions","organizations_url":"https://api.github.com/users/sauravmndl/orgs","repos_url":"https://api.github.com/users/sauravmndl/repos","events_url":"https://api.github.com/users/sauravmndl/events{/privacy}","received_events_url":"https://api.github.com/users/sauravmndl/received_events","type":"User","site_admin":false},"repo":{"id":122488808,"node_id":"MDEwOlJlcG9zaXRvcnkxMjI0ODg4MDg=","name":"service-fabrik-broker","full_name":"sauravmndl/service-fabrik-broker","private":false,"owner":{"login":"sauravmndl","id":17878349,"node_id":"MDQ6VXNlcjE3ODc4MzQ5","avatar_url":"https://avatars2.githubusercontent.com/u/17878349?v=4","gravatar_id":"","url":"https://api.github.com/users/sauravmndl","html_url":"https://github.com/sauravmndl","followers_url":"https://api.github.com/users/sauravmndl/followers","following_url":"https://api.github.com/users/sauravmndl/following{/other_user}","gists_url":"https://api.github.com/users/sauravmndl/gists{/gist_id}","starred_url":"https://api.github.com/users/sauravmndl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sauravmndl/subscriptions","organizations_url":"https://api.github.com/users/sauravmndl/orgs","repos_url":"https://api.github.com/users/sauravmndl/repos","events_url":"https://api.github.com/users/sauravmndl/events{/privacy}","received_events_url":"https://api.github.com/users/sauravmndl/received_events","type":"User","site_admin":false},"html_url":"https://github.com/sauravmndl/service-fabrik-broker","description":"Cloud Foundry service broker which provisions service instances as Docker containers and BOSH deployments.","fork":true,"url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker","forks_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/forks","keys_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/teams","hooks_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/hooks","issue_events_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/issues/events{/number}","events_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/events","assignees_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/assignees{/user}","branches_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/branches{/branch}","tags_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/tags","blobs_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/git/refs{/sha}","trees_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/statuses/{sha}","languages_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/languages","stargazers_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/stargazers","contributors_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/contributors","subscribers_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/subscribers","subscription_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/subscription","commits_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/commits{/sha}","git_commits_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/git/commits{/sha}","comments_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/comments{/number}","issue_comment_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/issues/comments{/number}","contents_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/contents/{+path}","compare_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/merges","archive_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/downloads","issues_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/issues{/number}","pulls_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/pulls{/number}","milestones_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/milestones{/number}","notifications_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/labels{/name}","releases_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/releases{/id}","deployments_url":"https://api.github.com/repos/sauravmndl/service-fabrik-broker/deployments","created_at":"2018-02-22T14:22:38Z","updated_at":"2018-10-24T08:02:31Z","pushed_at":"2018-11-07T14:42:24Z","git_url":"git://github.com/sauravmndl/service-fabrik-broker.git","ssh_url":"git@github.com:sauravmndl/service-fabrik-broker.git","clone_url":"https://github.com/sauravmndl/service-fabrik-broker.git","svn_url":"https://github.com/sauravmndl/service-fabrik-broker","homepage":"","size":7975,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"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":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"cloudfoundry-incubator:master","ref":"master","sha":"54c9b1e137fdd20fbb04f43af6351b277f2cb56d","user":{"login":"cloudfoundry-incubator","id":5680605,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU2ODA2MDU=","avatar_url":"https://avatars0.githubusercontent.com/u/5680605?v=4","gravatar_id":"","url":"https://api.github.com/users/cloudfoundry-incubator","html_url":"https://github.com/cloudfoundry-incubator","followers_url":"https://api.github.com/users/cloudfoundry-incubator/followers","following_url":"https://api.github.com/users/cloudfoundry-incubator/following{/other_user}","gists_url":"https://api.github.com/users/cloudfoundry-incubator/gists{/gist_id}","starred_url":"https://api.github.com/users/cloudfoundry-incubator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cloudfoundry-incubator/subscriptions","organizations_url":"https://api.github.com/users/cloudfoundry-incubator/orgs","repos_url":"https://api.github.com/users/cloudfoundry-incubator/repos","events_url":"https://api.github.com/users/cloudfoundry-incubator/events{/privacy}","received_events_url":"https://api.github.com/users/cloudfoundry-incubator/received_events","type":"Organization","site_admin":false},"repo":{"id":68716409,"node_id":"MDEwOlJlcG9zaXRvcnk2ODcxNjQwOQ==","name":"service-fabrik-broker","full_name":"cloudfoundry-incubator/service-fabrik-broker","private":false,"owner":{"login":"cloudfoundry-incubator","id":5680605,"node_id":"MDEyOk9yZ2FuaXphdGlvbjU2ODA2MDU=","avatar_url":"https://avatars0.githubusercontent.com/u/5680605?v=4","gravatar_id":"","url":"https://api.github.com/users/cloudfoundry-incubator","html_url":"https://github.com/cloudfoundry-incubator","followers_url":"https://api.github.com/users/cloudfoundry-incubator/followers","following_url":"https://api.github.com/users/cloudfoundry-incubator/following{/other_user}","gists_url":"https://api.github.com/users/cloudfoundry-incubator/gists{/gist_id}","starred_url":"https://api.github.com/users/cloudfoundry-incubator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cloudfoundry-incubator/subscriptions","organizations_url":"https://api.github.com/users/cloudfoundry-incubator/orgs","repos_url":"https://api.github.com/users/cloudfoundry-incubator/repos","events_url":"https://api.github.com/users/cloudfoundry-incubator/events{/privacy}","received_events_url":"https://api.github.com/users/cloudfoundry-incubator/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/cloudfoundry-incubator/service-fabrik-broker","description":"Cloud Foundry service broker which provisions service instances as Docker containers and BOSH deployments.","fork":false,"url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker","forks_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/forks","keys_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/teams","hooks_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/hooks","issue_events_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/issues/events{/number}","events_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/events","assignees_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/assignees{/user}","branches_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/branches{/branch}","tags_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/tags","blobs_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/git/refs{/sha}","trees_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/statuses/{sha}","languages_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/languages","stargazers_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/stargazers","contributors_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/contributors","subscribers_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/subscribers","subscription_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/subscription","commits_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/commits{/sha}","git_commits_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/git/commits{/sha}","comments_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/comments{/number}","issue_comment_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/issues/comments{/number}","contents_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/contents/{+path}","compare_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/merges","archive_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/downloads","issues_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/issues{/number}","pulls_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls{/number}","milestones_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/milestones{/number}","notifications_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/labels{/name}","releases_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/releases{/id}","deployments_url":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/deployments","created_at":"2016-09-20T13:48:13Z","updated_at":"2018-11-05T04:12:21Z","pushed_at":"2018-11-07T14:42:25Z","git_url":"git://github.com/cloudfoundry-incubator/service-fabrik-broker.git","ssh_url":"git@github.com:cloudfoundry-incubator/service-fabrik-broker.git","clone_url":"https://github.com/cloudfoundry-incubator/service-fabrik-broker.git","svn_url":"https://github.com/cloudfoundry-incubator/service-fabrik-broker","homepage":"","size":8218,"stargazers_count":19,"watchers_count":19,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":26,"mirror_url":null,"archived":false,"open_issues_count":18,"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":26,"open_issues":18,"watchers":19,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441"},"html":{"href":"https://github.com/cloudfoundry-incubator/service-fabrik-broker/pull/441"},"issue":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/issues/441"},"comments":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/issues/441/comments"},"review_comments":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441/comments"},"review_comment":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/pulls/441/commits"},"statuses":{"href":"https://api.github.com/repos/cloudfoundry-incubator/service-fabrik-broker/statuses/190b7fab1bcbac3a06f8f75eafc1df010966fca6"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"kamath-prasad"}}