{"action":"created","comment":{"url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/comments/177979313","pull_request_review_id":107955330,"id":177979313,"diff_hunk":"@@ -0,0 +1,106 @@\n+\n+--- Auxiliary module used to extract dogstats deamon initialization methods, incrementation of metrics\n+-- and calls to other useful functions\n+-- employed to measure calls to the Oauth provider: number, duration, etc.\n+\n+local Dogstatsd = {}\n+\n+function Dogstatsd:new(o)\n+    o = o or {}\n+    setmetatable(o, self)\n+    self.__index = self\n+    return o\n+end\n+\n+--- Loads a lua gracefully. If the module doesn't exist the exception is caught, logged and the execution continues\n+-- @param module path to the module to be loaded\n+-- @return The loaded module, or nil if the module cannot be loaded\n+--\n+local function loadrequire(module)\n+    ngx.log(ngx.DEBUG, \"Loading module [\" .. tostring(module) .. \"]\")\n+    local function requiref(module)\n+        return require(module)\n+    end\n+\n+    local status, result = pcall(requiref, module)\n+    if not (status) then\n+        ngx.log(ngx.WARN, \"Could not load module [\", module, \"]. Error \", result)\n+        return nil\n+    end\n+\n+    return result\n+end\n+\n+local dogstatsd\n+\n+--- Returns an instance of dogstatsd only if it does not already exist. Returns the instance if the feature is enabled\n+-- @param none\n+-- @return An instance of dogstatsd or nil if the class cannot be instantiated\n+--\n+local function getDogstatsd()\n+    local dogstatsHost = ngx.var.dogstatsHost\n+    if ngx.var.isDogstatsEnabled == nil or ngx.var.isDogstatsEnabled == \"false\" then","path":"src/lua/api-gateway/dogstatsd/Dogstatsd.lua","position":42,"original_position":42,"commit_id":"26cf09dd3298353d723ea42715d67713ded55437","original_commit_id":"26cf09dd3298353d723ea42715d67713ded55437","user":{"login":"andralungu","id":2550549,"avatar_url":"https://avatars1.githubusercontent.com/u/2550549?v=4","gravatar_id":"","url":"https://api.github.com/users/andralungu","html_url":"https://github.com/andralungu","followers_url":"https://api.github.com/users/andralungu/followers","following_url":"https://api.github.com/users/andralungu/following{/other_user}","gists_url":"https://api.github.com/users/andralungu/gists{/gist_id}","starred_url":"https://api.github.com/users/andralungu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andralungu/subscriptions","organizations_url":"https://api.github.com/users/andralungu/orgs","repos_url":"https://api.github.com/users/andralungu/repos","events_url":"https://api.github.com/users/andralungu/events{/privacy}","received_events_url":"https://api.github.com/users/andralungu/received_events","type":"User","site_admin":false},"body":"This is Alex's code, but sure 👍 will do.","created_at":"2018-03-29T08:02:43Z","updated_at":"2018-03-29T08:02:43Z","html_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation/pull/53#discussion_r177979313","pull_request_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/comments/177979313"},"html":{"href":"https://github.com/adobe-apiplatform/api-gateway-request-validation/pull/53#discussion_r177979313"},"pull_request":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53"}},"in_reply_to_id":177974587},"pull_request":{"url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53","id":176442736,"html_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation/pull/53","diff_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation/pull/53.diff","patch_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation/pull/53.patch","issue_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/53","number":53,"state":"open","locked":false,"title":"Oauth Client Dogstatsd Integration","user":{"login":"andralungu","id":2550549,"avatar_url":"https://avatars1.githubusercontent.com/u/2550549?v=4","gravatar_id":"","url":"https://api.github.com/users/andralungu","html_url":"https://github.com/andralungu","followers_url":"https://api.github.com/users/andralungu/followers","following_url":"https://api.github.com/users/andralungu/following{/other_user}","gists_url":"https://api.github.com/users/andralungu/gists{/gist_id}","starred_url":"https://api.github.com/users/andralungu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andralungu/subscriptions","organizations_url":"https://api.github.com/users/andralungu/orgs","repos_url":"https://api.github.com/users/andralungu/repos","events_url":"https://api.github.com/users/andralungu/events{/privacy}","received_events_url":"https://api.github.com/users/andralungu/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-03-21T11:10:53Z","updated_at":"2018-03-29T08:02:43Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4677f0f5529b808f5ff2d41f298851b5a053b15a","assignee":null,"assignees":[],"requested_reviewers":[{"login":"vdatcu","id":11957487,"avatar_url":"https://avatars1.githubusercontent.com/u/11957487?v=4","gravatar_id":"","url":"https://api.github.com/users/vdatcu","html_url":"https://github.com/vdatcu","followers_url":"https://api.github.com/users/vdatcu/followers","following_url":"https://api.github.com/users/vdatcu/following{/other_user}","gists_url":"https://api.github.com/users/vdatcu/gists{/gist_id}","starred_url":"https://api.github.com/users/vdatcu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vdatcu/subscriptions","organizations_url":"https://api.github.com/users/vdatcu/orgs","repos_url":"https://api.github.com/users/vdatcu/repos","events_url":"https://api.github.com/users/vdatcu/events{/privacy}","received_events_url":"https://api.github.com/users/vdatcu/received_events","type":"User","site_admin":false},{"login":"constantincristian","id":19434067,"avatar_url":"https://avatars2.githubusercontent.com/u/19434067?v=4","gravatar_id":"","url":"https://api.github.com/users/constantincristian","html_url":"https://github.com/constantincristian","followers_url":"https://api.github.com/users/constantincristian/followers","following_url":"https://api.github.com/users/constantincristian/following{/other_user}","gists_url":"https://api.github.com/users/constantincristian/gists{/gist_id}","starred_url":"https://api.github.com/users/constantincristian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/constantincristian/subscriptions","organizations_url":"https://api.github.com/users/constantincristian/orgs","repos_url":"https://api.github.com/users/constantincristian/repos","events_url":"https://api.github.com/users/constantincristian/events{/privacy}","received_events_url":"https://api.github.com/users/constantincristian/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53/commits","review_comments_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53/comments","review_comment_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/comments{/number}","comments_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/53/comments","statuses_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/statuses/26cf09dd3298353d723ea42715d67713ded55437","head":{"label":"adobe-apiplatform:dogstat_poc","ref":"dogstat_poc","sha":"26cf09dd3298353d723ea42715d67713ded55437","user":{"login":"adobe-apiplatform","id":13855477,"avatar_url":"https://avatars2.githubusercontent.com/u/13855477?v=4","gravatar_id":"","url":"https://api.github.com/users/adobe-apiplatform","html_url":"https://github.com/adobe-apiplatform","followers_url":"https://api.github.com/users/adobe-apiplatform/followers","following_url":"https://api.github.com/users/adobe-apiplatform/following{/other_user}","gists_url":"https://api.github.com/users/adobe-apiplatform/gists{/gist_id}","starred_url":"https://api.github.com/users/adobe-apiplatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adobe-apiplatform/subscriptions","organizations_url":"https://api.github.com/users/adobe-apiplatform/orgs","repos_url":"https://api.github.com/users/adobe-apiplatform/repos","events_url":"https://api.github.com/users/adobe-apiplatform/events{/privacy}","received_events_url":"https://api.github.com/users/adobe-apiplatform/received_events","type":"Organization","site_admin":false},"repo":{"id":36750881,"name":"api-gateway-request-validation","full_name":"adobe-apiplatform/api-gateway-request-validation","owner":{"login":"adobe-apiplatform","id":13855477,"avatar_url":"https://avatars2.githubusercontent.com/u/13855477?v=4","gravatar_id":"","url":"https://api.github.com/users/adobe-apiplatform","html_url":"https://github.com/adobe-apiplatform","followers_url":"https://api.github.com/users/adobe-apiplatform/followers","following_url":"https://api.github.com/users/adobe-apiplatform/following{/other_user}","gists_url":"https://api.github.com/users/adobe-apiplatform/gists{/gist_id}","starred_url":"https://api.github.com/users/adobe-apiplatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adobe-apiplatform/subscriptions","organizations_url":"https://api.github.com/users/adobe-apiplatform/orgs","repos_url":"https://api.github.com/users/adobe-apiplatform/repos","events_url":"https://api.github.com/users/adobe-apiplatform/events{/privacy}","received_events_url":"https://api.github.com/users/adobe-apiplatform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation","description":"API Request Validation framework","fork":false,"url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation","forks_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/forks","keys_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/teams","hooks_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/hooks","issue_events_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/events{/number}","events_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/events","assignees_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/assignees{/user}","branches_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/branches{/branch}","tags_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/tags","blobs_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/refs{/sha}","trees_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/statuses/{sha}","languages_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/languages","stargazers_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/stargazers","contributors_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/contributors","subscribers_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/subscribers","subscription_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/subscription","commits_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/commits{/sha}","git_commits_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/commits{/sha}","comments_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/comments{/number}","issue_comment_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/comments{/number}","contents_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/contents/{+path}","compare_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/merges","archive_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/downloads","issues_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues{/number}","pulls_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls{/number}","milestones_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/milestones{/number}","notifications_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/labels{/name}","releases_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/releases{/id}","deployments_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/deployments","created_at":"2015-06-02T17:48:42Z","updated_at":"2018-03-26T12:38:46Z","pushed_at":"2018-03-28T15:04:47Z","git_url":"git://github.com/adobe-apiplatform/api-gateway-request-validation.git","ssh_url":"git@github.com:adobe-apiplatform/api-gateway-request-validation.git","clone_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation.git","svn_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation","homepage":"","size":1283,"stargazers_count":15,"watchers_count":15,"language":"Perl","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":6,"mirror_url":null,"archived":false,"open_issues_count":5,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":6,"open_issues":5,"watchers":15,"default_branch":"master"}},"base":{"label":"adobe-apiplatform:master","ref":"master","sha":"96f66c08bc6789038c8cfe4571b786b8e24d8d3a","user":{"login":"adobe-apiplatform","id":13855477,"avatar_url":"https://avatars2.githubusercontent.com/u/13855477?v=4","gravatar_id":"","url":"https://api.github.com/users/adobe-apiplatform","html_url":"https://github.com/adobe-apiplatform","followers_url":"https://api.github.com/users/adobe-apiplatform/followers","following_url":"https://api.github.com/users/adobe-apiplatform/following{/other_user}","gists_url":"https://api.github.com/users/adobe-apiplatform/gists{/gist_id}","starred_url":"https://api.github.com/users/adobe-apiplatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adobe-apiplatform/subscriptions","organizations_url":"https://api.github.com/users/adobe-apiplatform/orgs","repos_url":"https://api.github.com/users/adobe-apiplatform/repos","events_url":"https://api.github.com/users/adobe-apiplatform/events{/privacy}","received_events_url":"https://api.github.com/users/adobe-apiplatform/received_events","type":"Organization","site_admin":false},"repo":{"id":36750881,"name":"api-gateway-request-validation","full_name":"adobe-apiplatform/api-gateway-request-validation","owner":{"login":"adobe-apiplatform","id":13855477,"avatar_url":"https://avatars2.githubusercontent.com/u/13855477?v=4","gravatar_id":"","url":"https://api.github.com/users/adobe-apiplatform","html_url":"https://github.com/adobe-apiplatform","followers_url":"https://api.github.com/users/adobe-apiplatform/followers","following_url":"https://api.github.com/users/adobe-apiplatform/following{/other_user}","gists_url":"https://api.github.com/users/adobe-apiplatform/gists{/gist_id}","starred_url":"https://api.github.com/users/adobe-apiplatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adobe-apiplatform/subscriptions","organizations_url":"https://api.github.com/users/adobe-apiplatform/orgs","repos_url":"https://api.github.com/users/adobe-apiplatform/repos","events_url":"https://api.github.com/users/adobe-apiplatform/events{/privacy}","received_events_url":"https://api.github.com/users/adobe-apiplatform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation","description":"API Request Validation framework","fork":false,"url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation","forks_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/forks","keys_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/teams","hooks_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/hooks","issue_events_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/events{/number}","events_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/events","assignees_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/assignees{/user}","branches_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/branches{/branch}","tags_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/tags","blobs_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/refs{/sha}","trees_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/statuses/{sha}","languages_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/languages","stargazers_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/stargazers","contributors_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/contributors","subscribers_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/subscribers","subscription_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/subscription","commits_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/commits{/sha}","git_commits_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/git/commits{/sha}","comments_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/comments{/number}","issue_comment_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/comments{/number}","contents_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/contents/{+path}","compare_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/merges","archive_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/downloads","issues_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues{/number}","pulls_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls{/number}","milestones_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/milestones{/number}","notifications_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/labels{/name}","releases_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/releases{/id}","deployments_url":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/deployments","created_at":"2015-06-02T17:48:42Z","updated_at":"2018-03-26T12:38:46Z","pushed_at":"2018-03-28T15:04:47Z","git_url":"git://github.com/adobe-apiplatform/api-gateway-request-validation.git","ssh_url":"git@github.com:adobe-apiplatform/api-gateway-request-validation.git","clone_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation.git","svn_url":"https://github.com/adobe-apiplatform/api-gateway-request-validation","homepage":"","size":1283,"stargazers_count":15,"watchers_count":15,"language":"Perl","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":6,"mirror_url":null,"archived":false,"open_issues_count":5,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":6,"open_issues":5,"watchers":15,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53"},"html":{"href":"https://github.com/adobe-apiplatform/api-gateway-request-validation/pull/53"},"issue":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/53"},"comments":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/issues/53/comments"},"review_comments":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53/comments"},"review_comment":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/pulls/53/commits"},"statuses":{"href":"https://api.github.com/repos/adobe-apiplatform/api-gateway-request-validation/statuses/26cf09dd3298353d723ea42715d67713ded55437"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"andralungu"}}