{"action":"closed","number":560,"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/560","id":175116635,"html_url":"https://github.com/GoogleCloudPlatform/runtimes-common/pull/560","diff_url":"https://github.com/GoogleCloudPlatform/runtimes-common/pull/560.diff","patch_url":"https://github.com/GoogleCloudPlatform/runtimes-common/pull/560.patch","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/issues/560","number":560,"state":"closed","locked":false,"title":"Add Logging Support for CLI Lib.","user":{"login":"tejal29","id":1534539,"avatar_url":"https://avatars0.githubusercontent.com/u/1534539?v=4","gravatar_id":"","url":"https://api.github.com/users/tejal29","html_url":"https://github.com/tejal29","followers_url":"https://api.github.com/users/tejal29/followers","following_url":"https://api.github.com/users/tejal29/following{/other_user}","gists_url":"https://api.github.com/users/tejal29/gists{/gist_id}","starred_url":"https://api.github.com/users/tejal29/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tejal29/subscriptions","organizations_url":"https://api.github.com/users/tejal29/orgs","repos_url":"https://api.github.com/users/tejal29/repos","events_url":"https://api.github.com/users/tejal29/events{/privacy}","received_events_url":"https://api.github.com/users/tejal29/received_events","type":"User","site_admin":false},"body":"The Logging Module I have used is Logrus.\r\nI read an article which listed pros and cons of some of the GO Log modules used.\r\nLogrus has a lot of rich features like you can Set custom formatters,  redirect output to elsewhere, Add hooks.\r\nGlog was another potential candidate. But i chose Logrus over this.\r\n\r\nIn this Pr, \r\n1. Initialize logging\r\n2. Set the log level from Command line\r\n3. Add Hooks for Log.Panic and Log.Fatal to use Command.Exit.\r\n\r\n\r\nTODO:\r\nAdd logging DIR to write logs in a Dir. Probably add this in with the Viper Configs PR coming up.","created_at":"2018-03-15T00:01:18Z","updated_at":"2018-03-21T00:48:46Z","closed_at":"2018-03-21T00:48:46Z","merged_at":"2018-03-21T00:48:46Z","merge_commit_sha":"52aa7382482a429f1fd99e5eedb7659ce5fc44a3","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/560/commits","review_comments_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/560/comments","review_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/issues/560/comments","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/statuses/a2245b54b76fc5e56b7fc193af9502e1d7ff8e52","head":{"label":"tejal29:add_logging","ref":"add_logging","sha":"a2245b54b76fc5e56b7fc193af9502e1d7ff8e52","user":{"login":"tejal29","id":1534539,"avatar_url":"https://avatars0.githubusercontent.com/u/1534539?v=4","gravatar_id":"","url":"https://api.github.com/users/tejal29","html_url":"https://github.com/tejal29","followers_url":"https://api.github.com/users/tejal29/followers","following_url":"https://api.github.com/users/tejal29/following{/other_user}","gists_url":"https://api.github.com/users/tejal29/gists{/gist_id}","starred_url":"https://api.github.com/users/tejal29/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tejal29/subscriptions","organizations_url":"https://api.github.com/users/tejal29/orgs","repos_url":"https://api.github.com/users/tejal29/repos","events_url":"https://api.github.com/users/tejal29/events{/privacy}","received_events_url":"https://api.github.com/users/tejal29/received_events","type":"User","site_admin":false},"repo":{"id":121436149,"name":"runtimes-common","full_name":"tejal29/runtimes-common","owner":{"login":"tejal29","id":1534539,"avatar_url":"https://avatars0.githubusercontent.com/u/1534539?v=4","gravatar_id":"","url":"https://api.github.com/users/tejal29","html_url":"https://github.com/tejal29","followers_url":"https://api.github.com/users/tejal29/followers","following_url":"https://api.github.com/users/tejal29/following{/other_user}","gists_url":"https://api.github.com/users/tejal29/gists{/gist_id}","starred_url":"https://api.github.com/users/tejal29/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tejal29/subscriptions","organizations_url":"https://api.github.com/users/tejal29/orgs","repos_url":"https://api.github.com/users/tejal29/repos","events_url":"https://api.github.com/users/tejal29/events{/privacy}","received_events_url":"https://api.github.com/users/tejal29/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tejal29/runtimes-common","description":"Common tools used by the GCP runtimes.","fork":true,"url":"https://api.github.com/repos/tejal29/runtimes-common","forks_url":"https://api.github.com/repos/tejal29/runtimes-common/forks","keys_url":"https://api.github.com/repos/tejal29/runtimes-common/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tejal29/runtimes-common/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tejal29/runtimes-common/teams","hooks_url":"https://api.github.com/repos/tejal29/runtimes-common/hooks","issue_events_url":"https://api.github.com/repos/tejal29/runtimes-common/issues/events{/number}","events_url":"https://api.github.com/repos/tejal29/runtimes-common/events","assignees_url":"https://api.github.com/repos/tejal29/runtimes-common/assignees{/user}","branches_url":"https://api.github.com/repos/tejal29/runtimes-common/branches{/branch}","tags_url":"https://api.github.com/repos/tejal29/runtimes-common/tags","blobs_url":"https://api.github.com/repos/tejal29/runtimes-common/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tejal29/runtimes-common/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tejal29/runtimes-common/git/refs{/sha}","trees_url":"https://api.github.com/repos/tejal29/runtimes-common/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tejal29/runtimes-common/statuses/{sha}","languages_url":"https://api.github.com/repos/tejal29/runtimes-common/languages","stargazers_url":"https://api.github.com/repos/tejal29/runtimes-common/stargazers","contributors_url":"https://api.github.com/repos/tejal29/runtimes-common/contributors","subscribers_url":"https://api.github.com/repos/tejal29/runtimes-common/subscribers","subscription_url":"https://api.github.com/repos/tejal29/runtimes-common/subscription","commits_url":"https://api.github.com/repos/tejal29/runtimes-common/commits{/sha}","git_commits_url":"https://api.github.com/repos/tejal29/runtimes-common/git/commits{/sha}","comments_url":"https://api.github.com/repos/tejal29/runtimes-common/comments{/number}","issue_comment_url":"https://api.github.com/repos/tejal29/runtimes-common/issues/comments{/number}","contents_url":"https://api.github.com/repos/tejal29/runtimes-common/contents/{+path}","compare_url":"https://api.github.com/repos/tejal29/runtimes-common/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tejal29/runtimes-common/merges","archive_url":"https://api.github.com/repos/tejal29/runtimes-common/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tejal29/runtimes-common/downloads","issues_url":"https://api.github.com/repos/tejal29/runtimes-common/issues{/number}","pulls_url":"https://api.github.com/repos/tejal29/runtimes-common/pulls{/number}","milestones_url":"https://api.github.com/repos/tejal29/runtimes-common/milestones{/number}","notifications_url":"https://api.github.com/repos/tejal29/runtimes-common/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tejal29/runtimes-common/labels{/name}","releases_url":"https://api.github.com/repos/tejal29/runtimes-common/releases{/id}","deployments_url":"https://api.github.com/repos/tejal29/runtimes-common/deployments","created_at":"2018-02-13T21:00:48Z","updated_at":"2018-03-13T17:51:26Z","pushed_at":"2018-03-20T22:55:44Z","git_url":"git://github.com/tejal29/runtimes-common.git","ssh_url":"git@github.com:tejal29/runtimes-common.git","clone_url":"https://github.com/tejal29/runtimes-common.git","svn_url":"https://github.com/tejal29/runtimes-common","homepage":"","size":46439,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":false,"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":"GoogleCloudPlatform:master","ref":"master","sha":"c769ff727338fa7f846980c3e03cb2504bd22079","user":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars0.githubusercontent.com/u/2810941?v=4","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"repo":{"id":67721213,"name":"runtimes-common","full_name":"GoogleCloudPlatform/runtimes-common","owner":{"login":"GoogleCloudPlatform","id":2810941,"avatar_url":"https://avatars0.githubusercontent.com/u/2810941?v=4","gravatar_id":"","url":"https://api.github.com/users/GoogleCloudPlatform","html_url":"https://github.com/GoogleCloudPlatform","followers_url":"https://api.github.com/users/GoogleCloudPlatform/followers","following_url":"https://api.github.com/users/GoogleCloudPlatform/following{/other_user}","gists_url":"https://api.github.com/users/GoogleCloudPlatform/gists{/gist_id}","starred_url":"https://api.github.com/users/GoogleCloudPlatform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoogleCloudPlatform/subscriptions","organizations_url":"https://api.github.com/users/GoogleCloudPlatform/orgs","repos_url":"https://api.github.com/users/GoogleCloudPlatform/repos","events_url":"https://api.github.com/users/GoogleCloudPlatform/events{/privacy}","received_events_url":"https://api.github.com/users/GoogleCloudPlatform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GoogleCloudPlatform/runtimes-common","description":"Common tools used by the GCP runtimes.","fork":false,"url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common","forks_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/forks","keys_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/teams","hooks_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/hooks","issue_events_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/issues/events{/number}","events_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/events","assignees_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/assignees{/user}","branches_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/branches{/branch}","tags_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/tags","blobs_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/git/refs{/sha}","trees_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/statuses/{sha}","languages_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/languages","stargazers_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/stargazers","contributors_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/contributors","subscribers_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/subscribers","subscription_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/subscription","commits_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/commits{/sha}","git_commits_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/git/commits{/sha}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/comments{/number}","issue_comment_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/issues/comments{/number}","contents_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/contents/{+path}","compare_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/merges","archive_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/downloads","issues_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/issues{/number}","pulls_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls{/number}","milestones_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/milestones{/number}","notifications_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/labels{/name}","releases_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/releases{/id}","deployments_url":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/deployments","created_at":"2016-09-08T16:33:38Z","updated_at":"2018-03-20T21:43:29Z","pushed_at":"2018-03-21T00:48:46Z","git_url":"git://github.com/GoogleCloudPlatform/runtimes-common.git","ssh_url":"git@github.com:GoogleCloudPlatform/runtimes-common.git","clone_url":"https://github.com/GoogleCloudPlatform/runtimes-common.git","svn_url":"https://github.com/GoogleCloudPlatform/runtimes-common","homepage":"","size":46080,"stargazers_count":27,"watchers_count":27,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":35,"mirror_url":null,"archived":false,"open_issues_count":19,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":35,"open_issues":19,"watchers":27,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/560"},"html":{"href":"https://github.com/GoogleCloudPlatform/runtimes-common/pull/560"},"issue":{"href":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/issues/560"},"comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/issues/560/comments"},"review_comments":{"href":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/560/comments"},"review_comment":{"href":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/pulls/560/commits"},"statuses":{"href":"https://api.github.com/repos/GoogleCloudPlatform/runtimes-common/statuses/a2245b54b76fc5e56b7fc193af9502e1d7ff8e52"}},"author_association":"MEMBER","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"tejal29","id":1534539,"avatar_url":"https://avatars0.githubusercontent.com/u/1534539?v=4","gravatar_id":"","url":"https://api.github.com/users/tejal29","html_url":"https://github.com/tejal29","followers_url":"https://api.github.com/users/tejal29/followers","following_url":"https://api.github.com/users/tejal29/following{/other_user}","gists_url":"https://api.github.com/users/tejal29/gists{/gist_id}","starred_url":"https://api.github.com/users/tejal29/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tejal29/subscriptions","organizations_url":"https://api.github.com/users/tejal29/orgs","repos_url":"https://api.github.com/users/tejal29/repos","events_url":"https://api.github.com/users/tejal29/events{/privacy}","received_events_url":"https://api.github.com/users/tejal29/received_events","type":"User","site_admin":false},"comments":0,"review_comments":3,"maintainer_can_modify":false,"commits":5,"additions":156437,"deletions":7,"changed_files":298}}
{"actor":{"display_login":"tejal29"}}