{"action":"created","comment":{"url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/comments/30735161","id":30735161,"diff_hunk":"@@ -0,0 +1,255 @@\n+# -*- coding: utf-8 -*-\n+\n+# Copyright 2015 Telefonica Investigación y Desarrollo, S.A.U\n+#\n+# This file is part of FIWARE project.\n+#\n+# Licensed under the Apache License, Version 2.0 (the \"License\");\n+# you may not use this file except in compliance with the License.\n+#\n+# You may obtain a copy of the License at:\n+#\n+# http://www.apache.org/licenses/LICENSE-2.0\n+#\n+# Unless required by applicable law or agreed to in writing, software\n+# distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+#\n+# See the License for the specific language governing permissions and\n+# limitations under the License.\n+#\n+# For those usages not covered by the Apache version 2.0 License please\n+# contact with opensource@tid.es\n+\n+\n+import requests\n+import xmltodict\n+import xmldict\n+from json import JSONEncoder\n+from logger_utils import get_logger, log_print_request, log_print_response\n+\n+requests.packages.urllib3.disable_warnings()\n+logger = get_logger(\"restClientUtils\")\n+\n+\n+# HEADERS\n+HEADER_CONTENT_TYPE = u'content-type'\n+HEADER_ACCEPT = u'accept'\n+HEADER_REPRESENTATION_JSON = u'application/json'\n+HEADER_REPRESENTATION_XML = u'application/xml'\n+HEADER_REPRESENTATION_TEXTPLAIN = u'text/plain'\n+HEADER_AUTH_TOKEN = u'X-Auth-Token'\n+HEADER_TENANT_ID = u'Tenant-Id'\n+HEADER_TRANSACTION_ID = u'txid'\n+\n+# HTTP VERBS\n+HTTP_VERB_POST = 'post'\n+HTTP_VERB_GET = 'get'\n+HTTP_VERB_PUT = 'put'\n+HTTP_VERB_DELETE = 'delete'\n+HTTP_VERB_UPDATE = 'update'\n+\n+\n+# REST CLIENT PATTERS\n+API_ROOT_URL_ARG_NAME = 'api_root_url'\n+URL_ROOT_PATTERN = \"{protocol}://{host}:{port}\"\n+\n+\n+class RestClient(object):\n+\n+    api_root_url = None\n+\n+    def __init__(self, protocol, host, port, resource=None):\n+        \"\"\"\n+        This method init the RestClient with an URL ROOT Pattern using the specified params","path":"python-paasmanagerclient/qa_utils/rest_client_utils.py","position":64,"original_position":64,"commit_id":"d115fd345033eba2eca111c9abd95d809c42d599","original_commit_id":"dedb7a67ce8104aa18e57615f77ead8385bc30f3","user":{"login":"flopezag","id":1379796,"avatar_url":"https://avatars.githubusercontent.com/u/1379796?v=3","gravatar_id":"","url":"https://api.github.com/users/flopezag","html_url":"https://github.com/flopezag","followers_url":"https://api.github.com/users/flopezag/followers","following_url":"https://api.github.com/users/flopezag/following{/other_user}","gists_url":"https://api.github.com/users/flopezag/gists{/gist_id}","starred_url":"https://api.github.com/users/flopezag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/flopezag/subscriptions","organizations_url":"https://api.github.com/users/flopezag/orgs","repos_url":"https://api.github.com/users/flopezag/repos","events_url":"https://api.github.com/users/flopezag/events{/privacy}","received_events_url":"https://api.github.com/users/flopezag/received_events","type":"User","site_admin":false},"body":"this method inits","created_at":"2015-05-20T18:44:27Z","updated_at":"2015-05-20T18:44:27Z","html_url":"https://github.com/telefonicaid/fiware-paas/pull/217#discussion_r30735161","pull_request_url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217","_links":{"self":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/comments/30735161"},"html":{"href":"https://github.com/telefonicaid/fiware-paas/pull/217#discussion_r30735161"},"pull_request":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217"}}},"pull_request":{"url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217","id":34810073,"html_url":"https://github.com/telefonicaid/fiware-paas/pull/217","diff_url":"https://github.com/telefonicaid/fiware-paas/pull/217.diff","patch_url":"https://github.com/telefonicaid/fiware-paas/pull/217.patch","issue_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/217","number":217,"state":"open","locked":false,"title":"[QA] Python-PaaSManagerClient","user":{"login":"jframos","id":8695972,"avatar_url":"https://avatars.githubusercontent.com/u/8695972?v=3","gravatar_id":"","url":"https://api.github.com/users/jframos","html_url":"https://github.com/jframos","followers_url":"https://api.github.com/users/jframos/followers","following_url":"https://api.github.com/users/jframos/following{/other_user}","gists_url":"https://api.github.com/users/jframos/gists{/gist_id}","starred_url":"https://api.github.com/users/jframos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jframos/subscriptions","organizations_url":"https://api.github.com/users/jframos/orgs","repos_url":"https://api.github.com/users/jframos/repos","events_url":"https://api.github.com/users/jframos/events{/privacy}","received_events_url":"https://api.github.com/users/jframos/received_events","type":"User","site_admin":false},"body":"#### Reviewers\r\n@flopezag \r\n\r\n#### Description\r\nFirst version of Python-PaaSManagerClient for testing purposes. \r\nImplemented API operations:\r\n- Create new environment.\r\n- Delete environment.\r\n\r\nJekins is using these operations to test the PaaSManager service each 15 minutes.\r\n\r\n#### Testing\r\nJenkins","created_at":"2015-05-06T12:10:37Z","updated_at":"2015-05-20T18:44:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b2677f4661fbbd7bb1a3c044c10a447ddd542f3d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217/commits","review_comments_url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217/comments","review_comment_url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/comments{/number}","comments_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/217/comments","statuses_url":"https://api.github.com/repos/telefonicaid/fiware-paas/statuses/d115fd345033eba2eca111c9abd95d809c42d599","head":{"label":"telefonicaid:QA/python-paasmanagerclient","ref":"QA/python-paasmanagerclient","sha":"d115fd345033eba2eca111c9abd95d809c42d599","user":{"login":"telefonicaid","id":968363,"avatar_url":"https://avatars.githubusercontent.com/u/968363?v=3","gravatar_id":"","url":"https://api.github.com/users/telefonicaid","html_url":"https://github.com/telefonicaid","followers_url":"https://api.github.com/users/telefonicaid/followers","following_url":"https://api.github.com/users/telefonicaid/following{/other_user}","gists_url":"https://api.github.com/users/telefonicaid/gists{/gist_id}","starred_url":"https://api.github.com/users/telefonicaid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/telefonicaid/subscriptions","organizations_url":"https://api.github.com/users/telefonicaid/orgs","repos_url":"https://api.github.com/users/telefonicaid/repos","events_url":"https://api.github.com/users/telefonicaid/events{/privacy}","received_events_url":"https://api.github.com/users/telefonicaid/received_events","type":"Organization","site_admin":false},"repo":{"id":18406709,"name":"fiware-paas","full_name":"telefonicaid/fiware-paas","owner":{"login":"telefonicaid","id":968363,"avatar_url":"https://avatars.githubusercontent.com/u/968363?v=3","gravatar_id":"","url":"https://api.github.com/users/telefonicaid","html_url":"https://github.com/telefonicaid","followers_url":"https://api.github.com/users/telefonicaid/followers","following_url":"https://api.github.com/users/telefonicaid/following{/other_user}","gists_url":"https://api.github.com/users/telefonicaid/gists{/gist_id}","starred_url":"https://api.github.com/users/telefonicaid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/telefonicaid/subscriptions","organizations_url":"https://api.github.com/users/telefonicaid/orgs","repos_url":"https://api.github.com/users/telefonicaid/repos","events_url":"https://api.github.com/users/telefonicaid/events{/privacy}","received_events_url":"https://api.github.com/users/telefonicaid/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/telefonicaid/fiware-paas","description":"PaaS Manager repository of the OpenStack PaaS solution in the FI-WARE project.","fork":false,"url":"https://api.github.com/repos/telefonicaid/fiware-paas","forks_url":"https://api.github.com/repos/telefonicaid/fiware-paas/forks","keys_url":"https://api.github.com/repos/telefonicaid/fiware-paas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/telefonicaid/fiware-paas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/telefonicaid/fiware-paas/teams","hooks_url":"https://api.github.com/repos/telefonicaid/fiware-paas/hooks","issue_events_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/events{/number}","events_url":"https://api.github.com/repos/telefonicaid/fiware-paas/events","assignees_url":"https://api.github.com/repos/telefonicaid/fiware-paas/assignees{/user}","branches_url":"https://api.github.com/repos/telefonicaid/fiware-paas/branches{/branch}","tags_url":"https://api.github.com/repos/telefonicaid/fiware-paas/tags","blobs_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/refs{/sha}","trees_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/telefonicaid/fiware-paas/statuses/{sha}","languages_url":"https://api.github.com/repos/telefonicaid/fiware-paas/languages","stargazers_url":"https://api.github.com/repos/telefonicaid/fiware-paas/stargazers","contributors_url":"https://api.github.com/repos/telefonicaid/fiware-paas/contributors","subscribers_url":"https://api.github.com/repos/telefonicaid/fiware-paas/subscribers","subscription_url":"https://api.github.com/repos/telefonicaid/fiware-paas/subscription","commits_url":"https://api.github.com/repos/telefonicaid/fiware-paas/commits{/sha}","git_commits_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/commits{/sha}","comments_url":"https://api.github.com/repos/telefonicaid/fiware-paas/comments{/number}","issue_comment_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/comments{/number}","contents_url":"https://api.github.com/repos/telefonicaid/fiware-paas/contents/{+path}","compare_url":"https://api.github.com/repos/telefonicaid/fiware-paas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/telefonicaid/fiware-paas/merges","archive_url":"https://api.github.com/repos/telefonicaid/fiware-paas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/telefonicaid/fiware-paas/downloads","issues_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues{/number}","pulls_url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls{/number}","milestones_url":"https://api.github.com/repos/telefonicaid/fiware-paas/milestones{/number}","notifications_url":"https://api.github.com/repos/telefonicaid/fiware-paas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/telefonicaid/fiware-paas/labels{/name}","releases_url":"https://api.github.com/repos/telefonicaid/fiware-paas/releases{/id}","created_at":"2014-04-03T14:50:18Z","updated_at":"2015-05-04T13:02:22Z","pushed_at":"2015-05-20T14:09:36Z","git_url":"git://github.com/telefonicaid/fiware-paas.git","ssh_url":"git@github.com:telefonicaid/fiware-paas.git","clone_url":"https://github.com/telefonicaid/fiware-paas.git","svn_url":"https://github.com/telefonicaid/fiware-paas","homepage":null,"size":16726,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":1,"forks":9,"open_issues":1,"watchers":2,"default_branch":"develop"}},"base":{"label":"telefonicaid:develop","ref":"develop","sha":"07392669ad190afadd46cd5237f804252dd18f9f","user":{"login":"telefonicaid","id":968363,"avatar_url":"https://avatars.githubusercontent.com/u/968363?v=3","gravatar_id":"","url":"https://api.github.com/users/telefonicaid","html_url":"https://github.com/telefonicaid","followers_url":"https://api.github.com/users/telefonicaid/followers","following_url":"https://api.github.com/users/telefonicaid/following{/other_user}","gists_url":"https://api.github.com/users/telefonicaid/gists{/gist_id}","starred_url":"https://api.github.com/users/telefonicaid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/telefonicaid/subscriptions","organizations_url":"https://api.github.com/users/telefonicaid/orgs","repos_url":"https://api.github.com/users/telefonicaid/repos","events_url":"https://api.github.com/users/telefonicaid/events{/privacy}","received_events_url":"https://api.github.com/users/telefonicaid/received_events","type":"Organization","site_admin":false},"repo":{"id":18406709,"name":"fiware-paas","full_name":"telefonicaid/fiware-paas","owner":{"login":"telefonicaid","id":968363,"avatar_url":"https://avatars.githubusercontent.com/u/968363?v=3","gravatar_id":"","url":"https://api.github.com/users/telefonicaid","html_url":"https://github.com/telefonicaid","followers_url":"https://api.github.com/users/telefonicaid/followers","following_url":"https://api.github.com/users/telefonicaid/following{/other_user}","gists_url":"https://api.github.com/users/telefonicaid/gists{/gist_id}","starred_url":"https://api.github.com/users/telefonicaid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/telefonicaid/subscriptions","organizations_url":"https://api.github.com/users/telefonicaid/orgs","repos_url":"https://api.github.com/users/telefonicaid/repos","events_url":"https://api.github.com/users/telefonicaid/events{/privacy}","received_events_url":"https://api.github.com/users/telefonicaid/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/telefonicaid/fiware-paas","description":"PaaS Manager repository of the OpenStack PaaS solution in the FI-WARE project.","fork":false,"url":"https://api.github.com/repos/telefonicaid/fiware-paas","forks_url":"https://api.github.com/repos/telefonicaid/fiware-paas/forks","keys_url":"https://api.github.com/repos/telefonicaid/fiware-paas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/telefonicaid/fiware-paas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/telefonicaid/fiware-paas/teams","hooks_url":"https://api.github.com/repos/telefonicaid/fiware-paas/hooks","issue_events_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/events{/number}","events_url":"https://api.github.com/repos/telefonicaid/fiware-paas/events","assignees_url":"https://api.github.com/repos/telefonicaid/fiware-paas/assignees{/user}","branches_url":"https://api.github.com/repos/telefonicaid/fiware-paas/branches{/branch}","tags_url":"https://api.github.com/repos/telefonicaid/fiware-paas/tags","blobs_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/refs{/sha}","trees_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/telefonicaid/fiware-paas/statuses/{sha}","languages_url":"https://api.github.com/repos/telefonicaid/fiware-paas/languages","stargazers_url":"https://api.github.com/repos/telefonicaid/fiware-paas/stargazers","contributors_url":"https://api.github.com/repos/telefonicaid/fiware-paas/contributors","subscribers_url":"https://api.github.com/repos/telefonicaid/fiware-paas/subscribers","subscription_url":"https://api.github.com/repos/telefonicaid/fiware-paas/subscription","commits_url":"https://api.github.com/repos/telefonicaid/fiware-paas/commits{/sha}","git_commits_url":"https://api.github.com/repos/telefonicaid/fiware-paas/git/commits{/sha}","comments_url":"https://api.github.com/repos/telefonicaid/fiware-paas/comments{/number}","issue_comment_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/comments{/number}","contents_url":"https://api.github.com/repos/telefonicaid/fiware-paas/contents/{+path}","compare_url":"https://api.github.com/repos/telefonicaid/fiware-paas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/telefonicaid/fiware-paas/merges","archive_url":"https://api.github.com/repos/telefonicaid/fiware-paas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/telefonicaid/fiware-paas/downloads","issues_url":"https://api.github.com/repos/telefonicaid/fiware-paas/issues{/number}","pulls_url":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls{/number}","milestones_url":"https://api.github.com/repos/telefonicaid/fiware-paas/milestones{/number}","notifications_url":"https://api.github.com/repos/telefonicaid/fiware-paas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/telefonicaid/fiware-paas/labels{/name}","releases_url":"https://api.github.com/repos/telefonicaid/fiware-paas/releases{/id}","created_at":"2014-04-03T14:50:18Z","updated_at":"2015-05-04T13:02:22Z","pushed_at":"2015-05-20T14:09:36Z","git_url":"git://github.com/telefonicaid/fiware-paas.git","ssh_url":"git@github.com:telefonicaid/fiware-paas.git","clone_url":"https://github.com/telefonicaid/fiware-paas.git","svn_url":"https://github.com/telefonicaid/fiware-paas","homepage":null,"size":16726,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":1,"forks":9,"open_issues":1,"watchers":2,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217"},"html":{"href":"https://github.com/telefonicaid/fiware-paas/pull/217"},"issue":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/217"},"comments":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/issues/217/comments"},"review_comments":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217/comments"},"review_comment":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/pulls/217/commits"},"statuses":{"href":"https://api.github.com/repos/telefonicaid/fiware-paas/statuses/d115fd345033eba2eca111c9abd95d809c42d599"}}}}