{"action":"created","comment":{"url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/comments/85519702","pull_request_review_id":6231671,"id":85519702,"diff_hunk":"@@ -0,0 +1,212 @@\n+# Copyright (C) 2016 iNuron NV\n+#\n+# This file is part of Open vStorage Open Source Edition (OSE),\n+# as available from\n+#\n+#      http://www.openvstorage.org and\n+#      http://www.openvstorage.com.\n+#\n+# This file is free software; you can redistribute it and/or modify it\n+# under the terms of the GNU Affero General Public License v3 (GNU AGPLv3)\n+# as published by the Free Software Foundation, in version 3 as it comes\n+# in the LICENSE.txt file of the Open vStorage OSE distribution.\n+#\n+# Open vStorage is distributed in the hope that it will be useful,\n+# but WITHOUT ANY WARRANTY of any kind.\n+\n+from ovs.log.log_handler import LogHandler\n+from ovs.dal.lists.backendlist import BackendList\n+from ovs.dal.hybrids.albabackend import AlbaBackend\n+from ovs.dal.lists.backendtypelist import BackendTypeList\n+from ovs.dal.lists.albabackendlist import AlbaBackendList\n+from ovs.extensions.healthcheck.helpers.exceptions import PresetNotFoundError, AlbaBackendNotFoundError\n+\n+\n+class BackendHelper(object):\n+    \"\"\"\n+    BackendHelper class\n+    \"\"\"\n+    LOGGER = LogHandler.get(source='helpers', name=\"ci_backend\")\n+\n+    def __init__(self):\n+        pass\n+\n+    @staticmethod\n+    def get_alba_backend_guid_by_name(backend_name):\n+        \"\"\"\n+\n+        :param backend_name: name of a backend\n+        :type backend_name: str\n+        :return: alba_backend_guid\n+        :rtype: str\n+        \"\"\"\n+\n+        return BackendList.get_by_name(backend_name).alba_backend_guid\n+\n+    @staticmethod\n+    def get_backend_guid_by_name(backend_name):\n+        \"\"\"\n+\n+        :param backend_name: name of a backend\n+        :type backend_name: str\n+        :return: backend_guid\n+        :rtype: str\n+        \"\"\"\n+\n+        return BackendList.get_by_name(backend_name).guid\n+\n+    @staticmethod\n+    def get_backend_by_name(backend_name):\n+        \"\"\"\n+","path":"ovs/extensions/healthcheck/helpers/backend.py","position":null,"original_position":61,"commit_id":"084d154d696f9081b660337aa507b0a0b3e210d8","original_commit_id":"367747f291e5ef5aa6d2554b8790d08cecc80596","user":{"login":"jeroenmaelbrancke","id":2900612,"avatar_url":"https://avatars.githubusercontent.com/u/2900612?v=3","gravatar_id":"","url":"https://api.github.com/users/jeroenmaelbrancke","html_url":"https://github.com/jeroenmaelbrancke","followers_url":"https://api.github.com/users/jeroenmaelbrancke/followers","following_url":"https://api.github.com/users/jeroenmaelbrancke/following{/other_user}","gists_url":"https://api.github.com/users/jeroenmaelbrancke/gists{/gist_id}","starred_url":"https://api.github.com/users/jeroenmaelbrancke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeroenmaelbrancke/subscriptions","organizations_url":"https://api.github.com/users/jeroenmaelbrancke/orgs","repos_url":"https://api.github.com/users/jeroenmaelbrancke/repos","events_url":"https://api.github.com/users/jeroenmaelbrancke/events{/privacy}","received_events_url":"https://api.github.com/users/jeroenmaelbrancke/received_events","type":"User","site_admin":false},"body":"add info about the method","created_at":"2016-10-28T12:21:40Z","updated_at":"2016-10-28T12:24:44Z","html_url":"https://github.com/openvstorage/openvstorage-health-check/pull/126#discussion_r85519702","pull_request_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126","_links":{"self":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/comments/85519702"},"html":{"href":"https://github.com/openvstorage/openvstorage-health-check/pull/126#discussion_r85519702"},"pull_request":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126"}}},"pull_request":{"url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126","id":91370089,"html_url":"https://github.com/openvstorage/openvstorage-health-check/pull/126","diff_url":"https://github.com/openvstorage/openvstorage-health-check/pull/126.diff","patch_url":"https://github.com/openvstorage/openvstorage-health-check/pull/126.patch","issue_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/126","number":126,"state":"open","locked":false,"title":"Moved all DAL fetchings to appropriate helper class.","user":{"login":"JeffreyDevloo","id":17570109,"avatar_url":"https://avatars.githubusercontent.com/u/17570109?v=3","gravatar_id":"","url":"https://api.github.com/users/JeffreyDevloo","html_url":"https://github.com/JeffreyDevloo","followers_url":"https://api.github.com/users/JeffreyDevloo/followers","following_url":"https://api.github.com/users/JeffreyDevloo/following{/other_user}","gists_url":"https://api.github.com/users/JeffreyDevloo/gists{/gist_id}","starred_url":"https://api.github.com/users/JeffreyDevloo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JeffreyDevloo/subscriptions","organizations_url":"https://api.github.com/users/JeffreyDevloo/orgs","repos_url":"https://api.github.com/users/JeffreyDevloo/repos","events_url":"https://api.github.com/users/JeffreyDevloo/events{/privacy}","received_events_url":"https://api.github.com/users/JeffreyDevloo/received_events","type":"User","site_admin":false},"body":" When a DAL change has happened, only helpers would need changing.","created_at":"2016-10-28T12:06:52Z","updated_at":"2016-10-28T12:24:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f2d0250807867b74a98a7e22d997b621e6019ecc","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126/commits","review_comments_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126/comments","review_comment_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/126/comments","statuses_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/statuses/084d154d696f9081b660337aa507b0a0b3e210d8","head":{"label":"openvstorage:rely_on_helpers","ref":"rely_on_helpers","sha":"084d154d696f9081b660337aa507b0a0b3e210d8","user":{"login":"openvstorage","id":12763393,"avatar_url":"https://avatars.githubusercontent.com/u/12763393?v=3","gravatar_id":"","url":"https://api.github.com/users/openvstorage","html_url":"https://github.com/openvstorage","followers_url":"https://api.github.com/users/openvstorage/followers","following_url":"https://api.github.com/users/openvstorage/following{/other_user}","gists_url":"https://api.github.com/users/openvstorage/gists{/gist_id}","starred_url":"https://api.github.com/users/openvstorage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openvstorage/subscriptions","organizations_url":"https://api.github.com/users/openvstorage/orgs","repos_url":"https://api.github.com/users/openvstorage/repos","events_url":"https://api.github.com/users/openvstorage/events{/privacy}","received_events_url":"https://api.github.com/users/openvstorage/received_events","type":"Organization","site_admin":false},"repo":{"id":52349527,"name":"openvstorage-health-check","full_name":"openvstorage/openvstorage-health-check","owner":{"login":"openvstorage","id":12763393,"avatar_url":"https://avatars.githubusercontent.com/u/12763393?v=3","gravatar_id":"","url":"https://api.github.com/users/openvstorage","html_url":"https://github.com/openvstorage","followers_url":"https://api.github.com/users/openvstorage/followers","following_url":"https://api.github.com/users/openvstorage/following{/other_user}","gists_url":"https://api.github.com/users/openvstorage/gists{/gist_id}","starred_url":"https://api.github.com/users/openvstorage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openvstorage/subscriptions","organizations_url":"https://api.github.com/users/openvstorage/orgs","repos_url":"https://api.github.com/users/openvstorage/repos","events_url":"https://api.github.com/users/openvstorage/events{/privacy}","received_events_url":"https://api.github.com/users/openvstorage/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openvstorage/openvstorage-health-check","description":"The health check is classified as a monitoring, detection and healing tool for Open vStorage.","fork":false,"url":"https://api.github.com/repos/openvstorage/openvstorage-health-check","forks_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/forks","keys_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/teams","hooks_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/hooks","issue_events_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/events{/number}","events_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/events","assignees_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/assignees{/user}","branches_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/branches{/branch}","tags_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/tags","blobs_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/refs{/sha}","trees_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/statuses/{sha}","languages_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/languages","stargazers_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/stargazers","contributors_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/contributors","subscribers_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/subscribers","subscription_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/subscription","commits_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/commits{/sha}","git_commits_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/commits{/sha}","comments_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/comments{/number}","issue_comment_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/comments{/number}","contents_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/contents/{+path}","compare_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/merges","archive_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/downloads","issues_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues{/number}","pulls_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls{/number}","milestones_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/milestones{/number}","notifications_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/labels{/name}","releases_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/releases{/id}","deployments_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/deployments","created_at":"2016-02-23T10:05:01Z","updated_at":"2016-10-24T12:09:03Z","pushed_at":"2016-10-28T12:22:03Z","git_url":"git://github.com/openvstorage/openvstorage-health-check.git","ssh_url":"git@github.com:openvstorage/openvstorage-health-check.git","clone_url":"https://github.com/openvstorage/openvstorage-health-check.git","svn_url":"https://github.com/openvstorage/openvstorage-health-check","homepage":"","size":466,"stargazers_count":2,"watchers_count":2,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":20,"forks":4,"open_issues":20,"watchers":2,"default_branch":"master"}},"base":{"label":"openvstorage:master","ref":"master","sha":"f621b03c328c0cdd6e3df7bf7ce80e7916cedff6","user":{"login":"openvstorage","id":12763393,"avatar_url":"https://avatars.githubusercontent.com/u/12763393?v=3","gravatar_id":"","url":"https://api.github.com/users/openvstorage","html_url":"https://github.com/openvstorage","followers_url":"https://api.github.com/users/openvstorage/followers","following_url":"https://api.github.com/users/openvstorage/following{/other_user}","gists_url":"https://api.github.com/users/openvstorage/gists{/gist_id}","starred_url":"https://api.github.com/users/openvstorage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openvstorage/subscriptions","organizations_url":"https://api.github.com/users/openvstorage/orgs","repos_url":"https://api.github.com/users/openvstorage/repos","events_url":"https://api.github.com/users/openvstorage/events{/privacy}","received_events_url":"https://api.github.com/users/openvstorage/received_events","type":"Organization","site_admin":false},"repo":{"id":52349527,"name":"openvstorage-health-check","full_name":"openvstorage/openvstorage-health-check","owner":{"login":"openvstorage","id":12763393,"avatar_url":"https://avatars.githubusercontent.com/u/12763393?v=3","gravatar_id":"","url":"https://api.github.com/users/openvstorage","html_url":"https://github.com/openvstorage","followers_url":"https://api.github.com/users/openvstorage/followers","following_url":"https://api.github.com/users/openvstorage/following{/other_user}","gists_url":"https://api.github.com/users/openvstorage/gists{/gist_id}","starred_url":"https://api.github.com/users/openvstorage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openvstorage/subscriptions","organizations_url":"https://api.github.com/users/openvstorage/orgs","repos_url":"https://api.github.com/users/openvstorage/repos","events_url":"https://api.github.com/users/openvstorage/events{/privacy}","received_events_url":"https://api.github.com/users/openvstorage/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openvstorage/openvstorage-health-check","description":"The health check is classified as a monitoring, detection and healing tool for Open vStorage.","fork":false,"url":"https://api.github.com/repos/openvstorage/openvstorage-health-check","forks_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/forks","keys_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/teams","hooks_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/hooks","issue_events_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/events{/number}","events_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/events","assignees_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/assignees{/user}","branches_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/branches{/branch}","tags_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/tags","blobs_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/refs{/sha}","trees_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/statuses/{sha}","languages_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/languages","stargazers_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/stargazers","contributors_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/contributors","subscribers_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/subscribers","subscription_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/subscription","commits_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/commits{/sha}","git_commits_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/git/commits{/sha}","comments_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/comments{/number}","issue_comment_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/comments{/number}","contents_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/contents/{+path}","compare_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/merges","archive_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/downloads","issues_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues{/number}","pulls_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls{/number}","milestones_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/milestones{/number}","notifications_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/labels{/name}","releases_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/releases{/id}","deployments_url":"https://api.github.com/repos/openvstorage/openvstorage-health-check/deployments","created_at":"2016-02-23T10:05:01Z","updated_at":"2016-10-24T12:09:03Z","pushed_at":"2016-10-28T12:22:03Z","git_url":"git://github.com/openvstorage/openvstorage-health-check.git","ssh_url":"git@github.com:openvstorage/openvstorage-health-check.git","clone_url":"https://github.com/openvstorage/openvstorage-health-check.git","svn_url":"https://github.com/openvstorage/openvstorage-health-check","homepage":"","size":466,"stargazers_count":2,"watchers_count":2,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":20,"forks":4,"open_issues":20,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126"},"html":{"href":"https://github.com/openvstorage/openvstorage-health-check/pull/126"},"issue":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/126"},"comments":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/issues/126/comments"},"review_comments":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126/comments"},"review_comment":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/pulls/126/commits"},"statuses":{"href":"https://api.github.com/repos/openvstorage/openvstorage-health-check/statuses/084d154d696f9081b660337aa507b0a0b3e210d8"}}}}
{"actor":{"display_login":"jeroenmaelbrancke"}}