{"action":"created","comment":{"url":"https://api.github.com/repos/ManageIQ/manageiq/pulls/comments/50857543","id":50857543,"diff_hunk":"@@ -80,10 +80,10 @@ def entity_display_type(entity)\n           \"Container\" # the container entity itself\n         end\n       else\n-        if name.eql? \"Vm\"\n-          'VM'\n+        if entity.kind_of?(Vm)\n+          name.upcase # turn Vm to VM because it's an abbreviation","path":"app/services/container_topology_service.rb","position":7,"original_position":7,"commit_id":"0183596a4ca94aa67c9b4b4b666e2ba1418a93b2","original_commit_id":"0183596a4ca94aa67c9b4b4b666e2ba1418a93b2","user":{"login":"abonas","id":6277245,"avatar_url":"https://avatars.githubusercontent.com/u/6277245?v=3","gravatar_id":"","url":"https://api.github.com/users/abonas","html_url":"https://github.com/abonas","followers_url":"https://api.github.com/users/abonas/followers","following_url":"https://api.github.com/users/abonas/following{/other_user}","gists_url":"https://api.github.com/users/abonas/gists{/gist_id}","starred_url":"https://api.github.com/users/abonas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abonas/subscriptions","organizations_url":"https://api.github.com/users/abonas/orgs","repos_url":"https://api.github.com/users/abonas/repos","events_url":"https://api.github.com/users/abonas/events{/privacy}","received_events_url":"https://api.github.com/users/abonas/received_events","type":"User","site_admin":false},"body":"yes, it is for display purposes.\r\nVM is the only entity that is an abbreviation in the topology, so for all the rest this is irrelevant at the moment. btw what other entities are an abbreviation in miq? can't think of any. (for generic purposes)","created_at":"2016-01-26T16:20:30Z","updated_at":"2016-01-26T16:20:30Z","html_url":"https://github.com/ManageIQ/manageiq/pull/6341#discussion_r50857543","pull_request_url":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341","_links":{"self":{"href":"https://api.github.com/repos/ManageIQ/manageiq/pulls/comments/50857543"},"html":{"href":"https://github.com/ManageIQ/manageiq/pull/6341#discussion_r50857543"},"pull_request":{"href":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341"}}},"pull_request":{"url":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341","id":57206402,"html_url":"https://github.com/ManageIQ/manageiq/pull/6341","diff_url":"https://github.com/ManageIQ/manageiq/pull/6341.diff","patch_url":"https://github.com/ManageIQ/manageiq/pull/6341.patch","issue_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/6341","number":6341,"state":"open","locked":false,"title":"make some checks for vm and host more generic in topology service","user":{"login":"abonas","id":6277245,"avatar_url":"https://avatars.githubusercontent.com/u/6277245?v=3","gravatar_id":"","url":"https://api.github.com/users/abonas","html_url":"https://github.com/abonas","followers_url":"https://api.github.com/users/abonas/followers","following_url":"https://api.github.com/users/abonas/following{/other_user}","gists_url":"https://api.github.com/users/abonas/gists{/gist_id}","starred_url":"https://api.github.com/users/abonas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abonas/subscriptions","organizations_url":"https://api.github.com/users/abonas/orgs","repos_url":"https://api.github.com/users/abonas/repos","events_url":"https://api.github.com/users/abonas/events{/privacy}","received_events_url":"https://api.github.com/users/abonas/received_events","type":"User","site_admin":false},"body":"@miq-bot add_label refactor, providers/containers\r\n\r\n@jrafanie per one of your comments in #6266, I've started generalizing some types vs strings. \r\nit was really not the purpose of that PR, so I'm doing it here.","created_at":"2016-01-26T12:48:11Z","updated_at":"2016-01-26T16:20:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3e1c69ceb42a4fd27d60ca451befbb66753246bf","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341/commits","review_comments_url":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341/comments","review_comment_url":"https://api.github.com/repos/ManageIQ/manageiq/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/6341/comments","statuses_url":"https://api.github.com/repos/ManageIQ/manageiq/statuses/0183596a4ca94aa67c9b4b4b666e2ba1418a93b2","head":{"label":"abonas:refactorTopologyServiceHardcodedClass","ref":"refactorTopologyServiceHardcodedClass","sha":"0183596a4ca94aa67c9b4b4b666e2ba1418a93b2","user":{"login":"abonas","id":6277245,"avatar_url":"https://avatars.githubusercontent.com/u/6277245?v=3","gravatar_id":"","url":"https://api.github.com/users/abonas","html_url":"https://github.com/abonas","followers_url":"https://api.github.com/users/abonas/followers","following_url":"https://api.github.com/users/abonas/following{/other_user}","gists_url":"https://api.github.com/users/abonas/gists{/gist_id}","starred_url":"https://api.github.com/users/abonas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abonas/subscriptions","organizations_url":"https://api.github.com/users/abonas/orgs","repos_url":"https://api.github.com/users/abonas/repos","events_url":"https://api.github.com/users/abonas/events{/privacy}","received_events_url":"https://api.github.com/users/abonas/received_events","type":"User","site_admin":false},"repo":{"id":27865006,"name":"manageiq","full_name":"abonas/manageiq","owner":{"login":"abonas","id":6277245,"avatar_url":"https://avatars.githubusercontent.com/u/6277245?v=3","gravatar_id":"","url":"https://api.github.com/users/abonas","html_url":"https://github.com/abonas","followers_url":"https://api.github.com/users/abonas/followers","following_url":"https://api.github.com/users/abonas/following{/other_user}","gists_url":"https://api.github.com/users/abonas/gists{/gist_id}","starred_url":"https://api.github.com/users/abonas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/abonas/subscriptions","organizations_url":"https://api.github.com/users/abonas/orgs","repos_url":"https://api.github.com/users/abonas/repos","events_url":"https://api.github.com/users/abonas/events{/privacy}","received_events_url":"https://api.github.com/users/abonas/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/abonas/manageiq","description":"ManageIQ Cloud Management Platform","fork":true,"url":"https://api.github.com/repos/abonas/manageiq","forks_url":"https://api.github.com/repos/abonas/manageiq/forks","keys_url":"https://api.github.com/repos/abonas/manageiq/keys{/key_id}","collaborators_url":"https://api.github.com/repos/abonas/manageiq/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/abonas/manageiq/teams","hooks_url":"https://api.github.com/repos/abonas/manageiq/hooks","issue_events_url":"https://api.github.com/repos/abonas/manageiq/issues/events{/number}","events_url":"https://api.github.com/repos/abonas/manageiq/events","assignees_url":"https://api.github.com/repos/abonas/manageiq/assignees{/user}","branches_url":"https://api.github.com/repos/abonas/manageiq/branches{/branch}","tags_url":"https://api.github.com/repos/abonas/manageiq/tags","blobs_url":"https://api.github.com/repos/abonas/manageiq/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/abonas/manageiq/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/abonas/manageiq/git/refs{/sha}","trees_url":"https://api.github.com/repos/abonas/manageiq/git/trees{/sha}","statuses_url":"https://api.github.com/repos/abonas/manageiq/statuses/{sha}","languages_url":"https://api.github.com/repos/abonas/manageiq/languages","stargazers_url":"https://api.github.com/repos/abonas/manageiq/stargazers","contributors_url":"https://api.github.com/repos/abonas/manageiq/contributors","subscribers_url":"https://api.github.com/repos/abonas/manageiq/subscribers","subscription_url":"https://api.github.com/repos/abonas/manageiq/subscription","commits_url":"https://api.github.com/repos/abonas/manageiq/commits{/sha}","git_commits_url":"https://api.github.com/repos/abonas/manageiq/git/commits{/sha}","comments_url":"https://api.github.com/repos/abonas/manageiq/comments{/number}","issue_comment_url":"https://api.github.com/repos/abonas/manageiq/issues/comments{/number}","contents_url":"https://api.github.com/repos/abonas/manageiq/contents/{+path}","compare_url":"https://api.github.com/repos/abonas/manageiq/compare/{base}...{head}","merges_url":"https://api.github.com/repos/abonas/manageiq/merges","archive_url":"https://api.github.com/repos/abonas/manageiq/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/abonas/manageiq/downloads","issues_url":"https://api.github.com/repos/abonas/manageiq/issues{/number}","pulls_url":"https://api.github.com/repos/abonas/manageiq/pulls{/number}","milestones_url":"https://api.github.com/repos/abonas/manageiq/milestones{/number}","notifications_url":"https://api.github.com/repos/abonas/manageiq/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/abonas/manageiq/labels{/name}","releases_url":"https://api.github.com/repos/abonas/manageiq/releases{/id}","deployments_url":"https://api.github.com/repos/abonas/manageiq/deployments","created_at":"2014-12-11T10:02:50Z","updated_at":"2015-04-14T15:32:19Z","pushed_at":"2016-01-26T16:16:42Z","git_url":"git://github.com/abonas/manageiq.git","ssh_url":"git@github.com:abonas/manageiq.git","clone_url":"https://github.com/abonas/manageiq.git","svn_url":"https://github.com/abonas/manageiq","homepage":"manageiq.org","size":102426,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"ManageIQ:master","ref":"master","sha":"0467a1af18d42fa94e27f174bbd56ee24cac11aa","user":{"login":"ManageIQ","id":1125575,"avatar_url":"https://avatars.githubusercontent.com/u/1125575?v=3","gravatar_id":"","url":"https://api.github.com/users/ManageIQ","html_url":"https://github.com/ManageIQ","followers_url":"https://api.github.com/users/ManageIQ/followers","following_url":"https://api.github.com/users/ManageIQ/following{/other_user}","gists_url":"https://api.github.com/users/ManageIQ/gists{/gist_id}","starred_url":"https://api.github.com/users/ManageIQ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ManageIQ/subscriptions","organizations_url":"https://api.github.com/users/ManageIQ/orgs","repos_url":"https://api.github.com/users/ManageIQ/repos","events_url":"https://api.github.com/users/ManageIQ/events{/privacy}","received_events_url":"https://api.github.com/users/ManageIQ/received_events","type":"Organization","site_admin":false},"repo":{"id":20789757,"name":"manageiq","full_name":"ManageIQ/manageiq","owner":{"login":"ManageIQ","id":1125575,"avatar_url":"https://avatars.githubusercontent.com/u/1125575?v=3","gravatar_id":"","url":"https://api.github.com/users/ManageIQ","html_url":"https://github.com/ManageIQ","followers_url":"https://api.github.com/users/ManageIQ/followers","following_url":"https://api.github.com/users/ManageIQ/following{/other_user}","gists_url":"https://api.github.com/users/ManageIQ/gists{/gist_id}","starred_url":"https://api.github.com/users/ManageIQ/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ManageIQ/subscriptions","organizations_url":"https://api.github.com/users/ManageIQ/orgs","repos_url":"https://api.github.com/users/ManageIQ/repos","events_url":"https://api.github.com/users/ManageIQ/events{/privacy}","received_events_url":"https://api.github.com/users/ManageIQ/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ManageIQ/manageiq","description":"ManageIQ Cloud Management Platform","fork":false,"url":"https://api.github.com/repos/ManageIQ/manageiq","forks_url":"https://api.github.com/repos/ManageIQ/manageiq/forks","keys_url":"https://api.github.com/repos/ManageIQ/manageiq/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ManageIQ/manageiq/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ManageIQ/manageiq/teams","hooks_url":"https://api.github.com/repos/ManageIQ/manageiq/hooks","issue_events_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/events{/number}","events_url":"https://api.github.com/repos/ManageIQ/manageiq/events","assignees_url":"https://api.github.com/repos/ManageIQ/manageiq/assignees{/user}","branches_url":"https://api.github.com/repos/ManageIQ/manageiq/branches{/branch}","tags_url":"https://api.github.com/repos/ManageIQ/manageiq/tags","blobs_url":"https://api.github.com/repos/ManageIQ/manageiq/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ManageIQ/manageiq/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ManageIQ/manageiq/git/refs{/sha}","trees_url":"https://api.github.com/repos/ManageIQ/manageiq/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ManageIQ/manageiq/statuses/{sha}","languages_url":"https://api.github.com/repos/ManageIQ/manageiq/languages","stargazers_url":"https://api.github.com/repos/ManageIQ/manageiq/stargazers","contributors_url":"https://api.github.com/repos/ManageIQ/manageiq/contributors","subscribers_url":"https://api.github.com/repos/ManageIQ/manageiq/subscribers","subscription_url":"https://api.github.com/repos/ManageIQ/manageiq/subscription","commits_url":"https://api.github.com/repos/ManageIQ/manageiq/commits{/sha}","git_commits_url":"https://api.github.com/repos/ManageIQ/manageiq/git/commits{/sha}","comments_url":"https://api.github.com/repos/ManageIQ/manageiq/comments{/number}","issue_comment_url":"https://api.github.com/repos/ManageIQ/manageiq/issues/comments{/number}","contents_url":"https://api.github.com/repos/ManageIQ/manageiq/contents/{+path}","compare_url":"https://api.github.com/repos/ManageIQ/manageiq/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ManageIQ/manageiq/merges","archive_url":"https://api.github.com/repos/ManageIQ/manageiq/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ManageIQ/manageiq/downloads","issues_url":"https://api.github.com/repos/ManageIQ/manageiq/issues{/number}","pulls_url":"https://api.github.com/repos/ManageIQ/manageiq/pulls{/number}","milestones_url":"https://api.github.com/repos/ManageIQ/manageiq/milestones{/number}","notifications_url":"https://api.github.com/repos/ManageIQ/manageiq/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ManageIQ/manageiq/labels{/name}","releases_url":"https://api.github.com/repos/ManageIQ/manageiq/releases{/id}","deployments_url":"https://api.github.com/repos/ManageIQ/manageiq/deployments","created_at":"2014-06-13T02:31:26Z","updated_at":"2016-01-26T00:50:19Z","pushed_at":"2016-01-26T16:18:12Z","git_url":"git://github.com/ManageIQ/manageiq.git","ssh_url":"git@github.com:ManageIQ/manageiq.git","clone_url":"https://github.com/ManageIQ/manageiq.git","svn_url":"https://github.com/ManageIQ/manageiq","homepage":"manageiq.org","size":138295,"stargazers_count":198,"watchers_count":198,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":213,"mirror_url":null,"open_issues_count":516,"forks":213,"open_issues":516,"watchers":198,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341"},"html":{"href":"https://github.com/ManageIQ/manageiq/pull/6341"},"issue":{"href":"https://api.github.com/repos/ManageIQ/manageiq/issues/6341"},"comments":{"href":"https://api.github.com/repos/ManageIQ/manageiq/issues/6341/comments"},"review_comments":{"href":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341/comments"},"review_comment":{"href":"https://api.github.com/repos/ManageIQ/manageiq/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ManageIQ/manageiq/pulls/6341/commits"},"statuses":{"href":"https://api.github.com/repos/ManageIQ/manageiq/statuses/0183596a4ca94aa67c9b4b4b666e2ba1418a93b2"}}}}