{"action":"created","comment":{"url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/comments/181120407","pull_request_review_id":111669622,"id":181120407,"diff_hunk":"@@ -0,0 +1,209 @@\n+/*\n+ * ProActive Parallel Suite(TM):\n+ * The Open Source library for parallel and distributed\n+ * Workflows & Scheduling, Orchestration, Cloud Automation\n+ * and Big Data Analysis on Enterprise Grids & Clouds.\n+ *\n+ * Copyright (c) 2007 - 2017 ActiveEon\n+ * Contact: contact@activeeon.com\n+ *\n+ * This library is free software: you can redistribute it and/or\n+ * modify it under the terms of the GNU Affero General Public License\n+ * as published by the Free Software Foundation: version 3 of\n+ * the License.\n+ *\n+ * This program is distributed in the hope that it will be useful,\n+ * but WITHOUT ANY WARRANTY; without even the implied warranty of\n+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n+ * GNU Affero General Public License for more details.\n+ *\n+ * You should have received a copy of the GNU Affero General Public License\n+ * along with this program. If not, see <http://www.gnu.org/licenses/>.\n+ *\n+ * If needed, contact us to obtain a release under GPL Version 2 or 3\n+ * or a different license than the AGPL.\n+ */\n+package org.ow2.proactive_grid_cloud_portal.rm.client.monitoring.views.compact;\n+\n+import com.google.gwt.user.client.ui.FlowPanel;\n+import org.ow2.proactive_grid_cloud_portal.rm.client.NodeSource;\n+\n+import java.util.Comparator;\n+import java.util.LinkedList;\n+import java.util.List;\n+import java.util.Optional;\n+\n+/**\n+ * It is flow panel to draw compact representation of hodesources/hosts/nodes.\n+ * Underlying stucture (FlowPanel) is kind of ArrayList.\n+ * However, we have hierarchical structure (model)\n+ * So to represent model as flat structure we have to be able to identify\n+ * index of model elements. Where index is the position of item from model in\n+ * FlowPanel. Plus we should be quite fast in finding indexes (in case we have 20K nodes).\n+ *\n+ * Thus, to have at the same time hierarchical structure (model) and\n+ * be able to find any index of this model we keep always updated tilesNumber field\n+ * in HierarchyNodeSource and HierarchyHost.\n+ * For example: we want to update node. For this we need to find index of the tile which represents\n+ * this node. Initially index is zero. Then we sequentially go through nodesources,\n+ * hosts, and nodes. Until we find our node, we add to index value of tilesNumber field of HierarchyNodeSource\n+ * and HierarchyHost, and 1 for the case of Node.\n+ *\n+ * Host tilesNumber are ephemeral because CompactFlowPanel handle them by it self.\n+ * As soon there is node but there is no dedicated host for this node, host will be created.\n+ * Also, host will be deleted automatically as soon as it does not have nodes anymore.\n+ *\n+ */\n+public class CompactFlowPanel extends FlowPanel {","path":"rm-portal/src/main/java/org/ow2/proactive_grid_cloud_portal/rm/client/monitoring/views/compact/CompactFlowPanel.java","position":57,"original_position":57,"commit_id":"1369904a7a3c9f14a76355e6cb89721da3bbabeb","original_commit_id":"1369904a7a3c9f14a76355e6cb89721da3bbabeb","user":{"login":"sonarqube-activeeon","id":14940028,"avatar_url":"https://avatars1.githubusercontent.com/u/14940028?v=4","gravatar_id":"","url":"https://api.github.com/users/sonarqube-activeeon","html_url":"https://github.com/sonarqube-activeeon","followers_url":"https://api.github.com/users/sonarqube-activeeon/followers","following_url":"https://api.github.com/users/sonarqube-activeeon/following{/other_user}","gists_url":"https://api.github.com/users/sonarqube-activeeon/gists{/gist_id}","starred_url":"https://api.github.com/users/sonarqube-activeeon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sonarqube-activeeon/subscriptions","organizations_url":"https://api.github.com/users/sonarqube-activeeon/orgs","repos_url":"https://api.github.com/users/sonarqube-activeeon/repos","events_url":"https://api.github.com/users/sonarqube-activeeon/events{/privacy}","received_events_url":"https://api.github.com/users/sonarqube-activeeon/received_events","type":"User","site_admin":false},"body":"![MAJOR](https://sonarsource.github.io/sonar-github/severity-major.png 'Severity: MAJOR') This class has 6 parents which is greater than 5 authorized. [![rule](https://sonarsource.github.io/sonar-github/rule.png)](https://sonarcloud.io/coding_rules#rule_key=squid%3AMaximumInheritanceDepth)\n","created_at":"2018-04-12T15:19:09Z","updated_at":"2018-04-12T15:19:10Z","html_url":"https://github.com/ow2-proactive/scheduling-portal/pull/434#discussion_r181120407","pull_request_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/comments/181120407"},"html":{"href":"https://github.com/ow2-proactive/scheduling-portal/pull/434#discussion_r181120407"},"pull_request":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434"}}},"pull_request":{"url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434","id":179701598,"html_url":"https://github.com/ow2-proactive/scheduling-portal/pull/434","diff_url":"https://github.com/ow2-proactive/scheduling-portal/pull/434.diff","patch_url":"https://github.com/ow2-proactive/scheduling-portal/pull/434.patch","issue_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/issues/434","number":434,"state":"open","locked":false,"title":"Render CompactView by deltas","user":{"login":"Mykhailenko","id":761558,"avatar_url":"https://avatars3.githubusercontent.com/u/761558?v=4","gravatar_id":"","url":"https://api.github.com/users/Mykhailenko","html_url":"https://github.com/Mykhailenko","followers_url":"https://api.github.com/users/Mykhailenko/followers","following_url":"https://api.github.com/users/Mykhailenko/following{/other_user}","gists_url":"https://api.github.com/users/Mykhailenko/gists{/gist_id}","starred_url":"https://api.github.com/users/Mykhailenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mykhailenko/subscriptions","organizations_url":"https://api.github.com/users/Mykhailenko/orgs","repos_url":"https://api.github.com/users/Mykhailenko/repos","events_url":"https://api.github.com/users/Mykhailenko/events{/privacy}","received_events_url":"https://api.github.com/users/Mykhailenko/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-04-05T14:52:24Z","updated_at":"2018-04-12T15:19:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0815a7f4e843958683c2e08c77bf87ce02500980","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434/commits","review_comments_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434/comments","review_comment_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/issues/434/comments","statuses_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/statuses/1369904a7a3c9f14a76355e6cb89721da3bbabeb","head":{"label":"Mykhailenko:render-by-deltas","ref":"render-by-deltas","sha":"1369904a7a3c9f14a76355e6cb89721da3bbabeb","user":{"login":"Mykhailenko","id":761558,"avatar_url":"https://avatars3.githubusercontent.com/u/761558?v=4","gravatar_id":"","url":"https://api.github.com/users/Mykhailenko","html_url":"https://github.com/Mykhailenko","followers_url":"https://api.github.com/users/Mykhailenko/followers","following_url":"https://api.github.com/users/Mykhailenko/following{/other_user}","gists_url":"https://api.github.com/users/Mykhailenko/gists{/gist_id}","starred_url":"https://api.github.com/users/Mykhailenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mykhailenko/subscriptions","organizations_url":"https://api.github.com/users/Mykhailenko/orgs","repos_url":"https://api.github.com/users/Mykhailenko/repos","events_url":"https://api.github.com/users/Mykhailenko/events{/privacy}","received_events_url":"https://api.github.com/users/Mykhailenko/received_events","type":"User","site_admin":false},"repo":{"id":107128891,"name":"scheduling-portal","full_name":"Mykhailenko/scheduling-portal","owner":{"login":"Mykhailenko","id":761558,"avatar_url":"https://avatars3.githubusercontent.com/u/761558?v=4","gravatar_id":"","url":"https://api.github.com/users/Mykhailenko","html_url":"https://github.com/Mykhailenko","followers_url":"https://api.github.com/users/Mykhailenko/followers","following_url":"https://api.github.com/users/Mykhailenko/following{/other_user}","gists_url":"https://api.github.com/users/Mykhailenko/gists{/gist_id}","starred_url":"https://api.github.com/users/Mykhailenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mykhailenko/subscriptions","organizations_url":"https://api.github.com/users/Mykhailenko/orgs","repos_url":"https://api.github.com/users/Mykhailenko/repos","events_url":"https://api.github.com/users/Mykhailenko/events{/privacy}","received_events_url":"https://api.github.com/users/Mykhailenko/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Mykhailenko/scheduling-portal","description":null,"fork":true,"url":"https://api.github.com/repos/Mykhailenko/scheduling-portal","forks_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/forks","keys_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/teams","hooks_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/hooks","issue_events_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/issues/events{/number}","events_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/events","assignees_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/assignees{/user}","branches_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/branches{/branch}","tags_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/tags","blobs_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/git/refs{/sha}","trees_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/statuses/{sha}","languages_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/languages","stargazers_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/stargazers","contributors_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/contributors","subscribers_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/subscribers","subscription_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/subscription","commits_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/commits{/sha}","git_commits_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/git/commits{/sha}","comments_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/comments{/number}","issue_comment_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/issues/comments{/number}","contents_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/contents/{+path}","compare_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/merges","archive_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/downloads","issues_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/issues{/number}","pulls_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/pulls{/number}","milestones_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/milestones{/number}","notifications_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/labels{/name}","releases_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/releases{/id}","deployments_url":"https://api.github.com/repos/Mykhailenko/scheduling-portal/deployments","created_at":"2017-10-16T13:08:59Z","updated_at":"2018-04-04T16:16:48Z","pushed_at":"2018-04-12T15:11:51Z","git_url":"git://github.com/Mykhailenko/scheduling-portal.git","ssh_url":"git@github.com:Mykhailenko/scheduling-portal.git","clone_url":"https://github.com/Mykhailenko/scheduling-portal.git","svn_url":"https://github.com/Mykhailenko/scheduling-portal","homepage":"http://try.activeeon.com","size":118992,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ow2-proactive:master","ref":"master","sha":"613e24113727b0933c04a4dd9a8e49da4b0f01cf","user":{"login":"ow2-proactive","id":11553998,"avatar_url":"https://avatars1.githubusercontent.com/u/11553998?v=4","gravatar_id":"","url":"https://api.github.com/users/ow2-proactive","html_url":"https://github.com/ow2-proactive","followers_url":"https://api.github.com/users/ow2-proactive/followers","following_url":"https://api.github.com/users/ow2-proactive/following{/other_user}","gists_url":"https://api.github.com/users/ow2-proactive/gists{/gist_id}","starred_url":"https://api.github.com/users/ow2-proactive/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ow2-proactive/subscriptions","organizations_url":"https://api.github.com/users/ow2-proactive/orgs","repos_url":"https://api.github.com/users/ow2-proactive/repos","events_url":"https://api.github.com/users/ow2-proactive/events{/privacy}","received_events_url":"https://api.github.com/users/ow2-proactive/received_events","type":"Organization","site_admin":false},"repo":{"id":35725080,"name":"scheduling-portal","full_name":"ow2-proactive/scheduling-portal","owner":{"login":"ow2-proactive","id":11553998,"avatar_url":"https://avatars1.githubusercontent.com/u/11553998?v=4","gravatar_id":"","url":"https://api.github.com/users/ow2-proactive","html_url":"https://github.com/ow2-proactive","followers_url":"https://api.github.com/users/ow2-proactive/followers","following_url":"https://api.github.com/users/ow2-proactive/following{/other_user}","gists_url":"https://api.github.com/users/ow2-proactive/gists{/gist_id}","starred_url":"https://api.github.com/users/ow2-proactive/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ow2-proactive/subscriptions","organizations_url":"https://api.github.com/users/ow2-proactive/orgs","repos_url":"https://api.github.com/users/ow2-proactive/repos","events_url":"https://api.github.com/users/ow2-proactive/events{/privacy}","received_events_url":"https://api.github.com/users/ow2-proactive/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ow2-proactive/scheduling-portal","description":null,"fork":false,"url":"https://api.github.com/repos/ow2-proactive/scheduling-portal","forks_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/forks","keys_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/teams","hooks_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/hooks","issue_events_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/issues/events{/number}","events_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/events","assignees_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/assignees{/user}","branches_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/branches{/branch}","tags_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/tags","blobs_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/git/refs{/sha}","trees_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/statuses/{sha}","languages_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/languages","stargazers_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/stargazers","contributors_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/contributors","subscribers_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/subscribers","subscription_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/subscription","commits_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/commits{/sha}","git_commits_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/git/commits{/sha}","comments_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/comments{/number}","issue_comment_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/issues/comments{/number}","contents_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/contents/{+path}","compare_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/merges","archive_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/downloads","issues_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/issues{/number}","pulls_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls{/number}","milestones_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/milestones{/number}","notifications_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/labels{/name}","releases_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/releases{/id}","deployments_url":"https://api.github.com/repos/ow2-proactive/scheduling-portal/deployments","created_at":"2015-05-16T13:38:55Z","updated_at":"2018-04-09T12:47:14Z","pushed_at":"2018-04-12T15:11:52Z","git_url":"git://github.com/ow2-proactive/scheduling-portal.git","ssh_url":"git@github.com:ow2-proactive/scheduling-portal.git","clone_url":"https://github.com/ow2-proactive/scheduling-portal.git","svn_url":"https://github.com/ow2-proactive/scheduling-portal","homepage":"http://try.activeeon.com","size":118847,"stargazers_count":3,"watchers_count":3,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":29,"mirror_url":null,"archived":false,"open_issues_count":59,"license":{"key":"agpl-3.0","name":"GNU Affero General Public License v3.0","spdx_id":"AGPL-3.0","url":"https://api.github.com/licenses/agpl-3.0"},"forks":29,"open_issues":59,"watchers":3,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434"},"html":{"href":"https://github.com/ow2-proactive/scheduling-portal/pull/434"},"issue":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/issues/434"},"comments":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/issues/434/comments"},"review_comments":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434/comments"},"review_comment":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/pulls/434/commits"},"statuses":{"href":"https://api.github.com/repos/ow2-proactive/scheduling-portal/statuses/1369904a7a3c9f14a76355e6cb89721da3bbabeb"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"sonarqube-activeeon"}}