{"action":"created","comment":{"url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/comments/101514366","pull_request_review_id":22244317,"id":101514366,"diff_hunk":"@@ -91,26 +94,44 @@\n \tpublic static final String SERVER_START_ON_CREATION = \"org.jboss.tools.openshift.SERVER_START_ON_CREATION\";\n \n \tprivate static final Collection<String> EAP_LIKE_KEYWORDS = Collections.unmodifiableCollection(Arrays.asList(\"eap\", \"wildfly\"));\n+\t\n+\tprivate static final Collection<String> SERVER_ADDAPTER_ALLOWED_RESOURCE_TYPESS = Collections.unmodifiableCollection(Arrays.asList(ResourceKind.ROUTE,\n+\t                                                                                                                                   ResourceKind.SERVICE,\n+\t                                                                                                                                   ResourceKind.REPLICATION_CONTROLLER,\n+\t                                                                                                                                   ResourceKind.DEPLOYMENT_CONFIG,\n+\t                                                                                                                                   ResourceKind.POD));\n+\t\n+\t/**\n+\t * Checks if the resource is allowed for OpenShift server adapter.\n+\t * \n+\t * @param resource the OpenShift resource\n+\t * @return true if allowed\n+\t */\n+\tpublic static boolean isAllowedForServerAdapter(IResource resource) {\n+\t    return SERVER_ADDAPTER_ALLOWED_RESOURCE_TYPESS.stream().anyMatch(kind -> kind.equals(resource.getKind()));\n+\t}\n \n \tprivate static final String PACKAGE_JSON = \"package.json\"; //$NON-NLS-1$","path":"plugins/org.jboss.tools.openshift.core/src/org/jboss/tools/openshift/core/server/OpenShiftServerUtils.java","position":38,"original_position":38,"commit_id":"5ba9c5cdbadd256e5d138d054fd6dea81559b089","original_commit_id":"5ba9c5cdbadd256e5d138d054fd6dea81559b089","user":{"login":"rhdevelopers-ci","id":18214726,"avatar_url":"https://avatars.githubusercontent.com/u/18214726?v=3","gravatar_id":"","url":"https://api.github.com/users/rhdevelopers-ci","html_url":"https://github.com/rhdevelopers-ci","followers_url":"https://api.github.com/users/rhdevelopers-ci/followers","following_url":"https://api.github.com/users/rhdevelopers-ci/following{/other_user}","gists_url":"https://api.github.com/users/rhdevelopers-ci/gists{/gist_id}","starred_url":"https://api.github.com/users/rhdevelopers-ci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rhdevelopers-ci/subscriptions","organizations_url":"https://api.github.com/users/rhdevelopers-ci/orgs","repos_url":"https://api.github.com/users/rhdevelopers-ci/repos","events_url":"https://api.github.com/users/rhdevelopers-ci/events{/privacy}","received_events_url":"https://api.github.com/users/rhdevelopers-ci/received_events","type":"User","site_admin":false},"body":"![MINOR](https://raw.githubusercontent.com/SonarCommunity/sonar-github/master/images/severity-minor.png 'Severity: MINOR') Move this variable to comply with Java Code Conventions. [![rule](https://raw.githubusercontent.com/SonarCommunity/sonar-github/master/images/rule.png)](https://sonarqube.com/coding_rules#rule_key=squid%3AS1213)\n","created_at":"2017-02-16T13:13:17Z","updated_at":"2017-02-16T13:13:17Z","html_url":"https://github.com/jbosstools/jbosstools-openshift/pull/1422#discussion_r101514366","pull_request_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422","_links":{"self":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/comments/101514366"},"html":{"href":"https://github.com/jbosstools/jbosstools-openshift/pull/1422#discussion_r101514366"},"pull_request":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422"}}},"pull_request":{"url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422","id":106519185,"html_url":"https://github.com/jbosstools/jbosstools-openshift/pull/1422","diff_url":"https://github.com/jbosstools/jbosstools-openshift/pull/1422.diff","patch_url":"https://github.com/jbosstools/jbosstools-openshift/pull/1422.patch","issue_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/issues/1422","number":1422,"state":"open","locked":false,"title":"Jbide 23490","user":{"login":"adietish","id":25126,"avatar_url":"https://avatars.githubusercontent.com/u/25126?v=3","gravatar_id":"","url":"https://api.github.com/users/adietish","html_url":"https://github.com/adietish","followers_url":"https://api.github.com/users/adietish/followers","following_url":"https://api.github.com/users/adietish/following{/other_user}","gists_url":"https://api.github.com/users/adietish/gists{/gist_id}","starred_url":"https://api.github.com/users/adietish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adietish/subscriptions","organizations_url":"https://api.github.com/users/adietish/orgs","repos_url":"https://api.github.com/users/adietish/repos","events_url":"https://api.github.com/users/adietish/events{/privacy}","received_events_url":"https://api.github.com/users/adietish/received_events","type":"User","site_admin":false},"body":"# Pull Request Checklist\r\n## General\r\n* Is this a blocking issue or new feature? If yes, QE needs to +1 this PR\r\n\r\n## Code\r\n* Are method-/class-/variable-names meaningful?\r\n* Are methods concise, not too long?\r\n* Are catch blocks catching precise Exceptions only (no catch all)?\r\n\r\n## Testing\r\n* Are there unit-tests?\r\n* Are there integration tests (or at least a jira to tackle these)?\r\n* Is the non-happy path working, too?\r\n* Are other parts that use the same component still working fine?\r\n\r\n## Function\r\n* Does it work?\r\n","created_at":"2017-02-16T12:53:29Z","updated_at":"2017-02-16T13:13:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c7994dd7468a71e34398fcc4590ad30aecdcf369","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422/commits","review_comments_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422/comments","review_comment_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/issues/1422/comments","statuses_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/statuses/5ba9c5cdbadd256e5d138d054fd6dea81559b089","head":{"label":"adietish:JBIDE-23490","ref":"JBIDE-23490","sha":"5ba9c5cdbadd256e5d138d054fd6dea81559b089","user":{"login":"adietish","id":25126,"avatar_url":"https://avatars.githubusercontent.com/u/25126?v=3","gravatar_id":"","url":"https://api.github.com/users/adietish","html_url":"https://github.com/adietish","followers_url":"https://api.github.com/users/adietish/followers","following_url":"https://api.github.com/users/adietish/following{/other_user}","gists_url":"https://api.github.com/users/adietish/gists{/gist_id}","starred_url":"https://api.github.com/users/adietish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adietish/subscriptions","organizations_url":"https://api.github.com/users/adietish/orgs","repos_url":"https://api.github.com/users/adietish/repos","events_url":"https://api.github.com/users/adietish/events{/privacy}","received_events_url":"https://api.github.com/users/adietish/received_events","type":"User","site_admin":false},"repo":{"id":6351407,"name":"jbosstools-openshift","full_name":"adietish/jbosstools-openshift","owner":{"login":"adietish","id":25126,"avatar_url":"https://avatars.githubusercontent.com/u/25126?v=3","gravatar_id":"","url":"https://api.github.com/users/adietish","html_url":"https://github.com/adietish","followers_url":"https://api.github.com/users/adietish/followers","following_url":"https://api.github.com/users/adietish/following{/other_user}","gists_url":"https://api.github.com/users/adietish/gists{/gist_id}","starred_url":"https://api.github.com/users/adietish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adietish/subscriptions","organizations_url":"https://api.github.com/users/adietish/orgs","repos_url":"https://api.github.com/users/adietish/repos","events_url":"https://api.github.com/users/adietish/events{/privacy}","received_events_url":"https://api.github.com/users/adietish/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/adietish/jbosstools-openshift","description":"JBoss Tools :: OpenShift { openshift }","fork":true,"url":"https://api.github.com/repos/adietish/jbosstools-openshift","forks_url":"https://api.github.com/repos/adietish/jbosstools-openshift/forks","keys_url":"https://api.github.com/repos/adietish/jbosstools-openshift/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adietish/jbosstools-openshift/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adietish/jbosstools-openshift/teams","hooks_url":"https://api.github.com/repos/adietish/jbosstools-openshift/hooks","issue_events_url":"https://api.github.com/repos/adietish/jbosstools-openshift/issues/events{/number}","events_url":"https://api.github.com/repos/adietish/jbosstools-openshift/events","assignees_url":"https://api.github.com/repos/adietish/jbosstools-openshift/assignees{/user}","branches_url":"https://api.github.com/repos/adietish/jbosstools-openshift/branches{/branch}","tags_url":"https://api.github.com/repos/adietish/jbosstools-openshift/tags","blobs_url":"https://api.github.com/repos/adietish/jbosstools-openshift/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adietish/jbosstools-openshift/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adietish/jbosstools-openshift/git/refs{/sha}","trees_url":"https://api.github.com/repos/adietish/jbosstools-openshift/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adietish/jbosstools-openshift/statuses/{sha}","languages_url":"https://api.github.com/repos/adietish/jbosstools-openshift/languages","stargazers_url":"https://api.github.com/repos/adietish/jbosstools-openshift/stargazers","contributors_url":"https://api.github.com/repos/adietish/jbosstools-openshift/contributors","subscribers_url":"https://api.github.com/repos/adietish/jbosstools-openshift/subscribers","subscription_url":"https://api.github.com/repos/adietish/jbosstools-openshift/subscription","commits_url":"https://api.github.com/repos/adietish/jbosstools-openshift/commits{/sha}","git_commits_url":"https://api.github.com/repos/adietish/jbosstools-openshift/git/commits{/sha}","comments_url":"https://api.github.com/repos/adietish/jbosstools-openshift/comments{/number}","issue_comment_url":"https://api.github.com/repos/adietish/jbosstools-openshift/issues/comments{/number}","contents_url":"https://api.github.com/repos/adietish/jbosstools-openshift/contents/{+path}","compare_url":"https://api.github.com/repos/adietish/jbosstools-openshift/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adietish/jbosstools-openshift/merges","archive_url":"https://api.github.com/repos/adietish/jbosstools-openshift/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adietish/jbosstools-openshift/downloads","issues_url":"https://api.github.com/repos/adietish/jbosstools-openshift/issues{/number}","pulls_url":"https://api.github.com/repos/adietish/jbosstools-openshift/pulls{/number}","milestones_url":"https://api.github.com/repos/adietish/jbosstools-openshift/milestones{/number}","notifications_url":"https://api.github.com/repos/adietish/jbosstools-openshift/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adietish/jbosstools-openshift/labels{/name}","releases_url":"https://api.github.com/repos/adietish/jbosstools-openshift/releases{/id}","deployments_url":"https://api.github.com/repos/adietish/jbosstools-openshift/deployments","created_at":"2012-10-23T11:48:16Z","updated_at":"2015-05-05T14:50:36Z","pushed_at":"2017-02-16T12:53:18Z","git_url":"git://github.com/adietish/jbosstools-openshift.git","ssh_url":"git@github.com:adietish/jbosstools-openshift.git","clone_url":"https://github.com/adietish/jbosstools-openshift.git","svn_url":"https://github.com/adietish/jbosstools-openshift","homepage":"","size":17582,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"jbosstools:master","ref":"master","sha":"17849cfeabeb0b251c2b5f4e0daeec371e506806","user":{"login":"jbosstools","id":619871,"avatar_url":"https://avatars.githubusercontent.com/u/619871?v=3","gravatar_id":"","url":"https://api.github.com/users/jbosstools","html_url":"https://github.com/jbosstools","followers_url":"https://api.github.com/users/jbosstools/followers","following_url":"https://api.github.com/users/jbosstools/following{/other_user}","gists_url":"https://api.github.com/users/jbosstools/gists{/gist_id}","starred_url":"https://api.github.com/users/jbosstools/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jbosstools/subscriptions","organizations_url":"https://api.github.com/users/jbosstools/orgs","repos_url":"https://api.github.com/users/jbosstools/repos","events_url":"https://api.github.com/users/jbosstools/events{/privacy}","received_events_url":"https://api.github.com/users/jbosstools/received_events","type":"Organization","site_admin":false},"repo":{"id":6308288,"name":"jbosstools-openshift","full_name":"jbosstools/jbosstools-openshift","owner":{"login":"jbosstools","id":619871,"avatar_url":"https://avatars.githubusercontent.com/u/619871?v=3","gravatar_id":"","url":"https://api.github.com/users/jbosstools","html_url":"https://github.com/jbosstools","followers_url":"https://api.github.com/users/jbosstools/followers","following_url":"https://api.github.com/users/jbosstools/following{/other_user}","gists_url":"https://api.github.com/users/jbosstools/gists{/gist_id}","starred_url":"https://api.github.com/users/jbosstools/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jbosstools/subscriptions","organizations_url":"https://api.github.com/users/jbosstools/orgs","repos_url":"https://api.github.com/users/jbosstools/repos","events_url":"https://api.github.com/users/jbosstools/events{/privacy}","received_events_url":"https://api.github.com/users/jbosstools/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/jbosstools/jbosstools-openshift","description":"JBoss Tools :: OpenShift { openshift }","fork":false,"url":"https://api.github.com/repos/jbosstools/jbosstools-openshift","forks_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/forks","keys_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/teams","hooks_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/hooks","issue_events_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/issues/events{/number}","events_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/events","assignees_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/assignees{/user}","branches_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/branches{/branch}","tags_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/tags","blobs_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/git/refs{/sha}","trees_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/statuses/{sha}","languages_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/languages","stargazers_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/stargazers","contributors_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/contributors","subscribers_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/subscribers","subscription_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/subscription","commits_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/commits{/sha}","git_commits_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/git/commits{/sha}","comments_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/comments{/number}","issue_comment_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/issues/comments{/number}","contents_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/contents/{+path}","compare_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/merges","archive_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/downloads","issues_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/issues{/number}","pulls_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls{/number}","milestones_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/milestones{/number}","notifications_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/labels{/name}","releases_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/releases{/id}","deployments_url":"https://api.github.com/repos/jbosstools/jbosstools-openshift/deployments","created_at":"2012-10-20T11:23:01Z","updated_at":"2016-10-24T13:34:34Z","pushed_at":"2017-02-16T12:53:30Z","git_url":"git://github.com/jbosstools/jbosstools-openshift.git","ssh_url":"git@github.com:jbosstools/jbosstools-openshift.git","clone_url":"https://github.com/jbosstools/jbosstools-openshift.git","svn_url":"https://github.com/jbosstools/jbosstools-openshift","homepage":"","size":17520,"stargazers_count":7,"watchers_count":7,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":49,"mirror_url":null,"open_issues_count":8,"forks":49,"open_issues":8,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422"},"html":{"href":"https://github.com/jbosstools/jbosstools-openshift/pull/1422"},"issue":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/issues/1422"},"comments":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/issues/1422/comments"},"review_comments":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422/comments"},"review_comment":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/pulls/1422/commits"},"statuses":{"href":"https://api.github.com/repos/jbosstools/jbosstools-openshift/statuses/5ba9c5cdbadd256e5d138d054fd6dea81559b089"}}}}
{"actor":{"display_login":"rhdevelopers-ci"}}