{"action":"opened","number":2573,"pull_request":{"url":"https://api.github.com/repos/apache/zeppelin/pulls/2573","id":139968341,"html_url":"https://github.com/apache/zeppelin/pull/2573","diff_url":"https://github.com/apache/zeppelin/pull/2573.diff","patch_url":"https://github.com/apache/zeppelin/pull/2573.patch","issue_url":"https://api.github.com/repos/apache/zeppelin/issues/2573","number":2573,"state":"open","locked":false,"title":"[ZEPPELIN-2920] move commonly used error handlers to util (FRONT)","user":{"login":"1ambda","id":4968473,"avatar_url":"https://avatars3.githubusercontent.com/u/4968473?v=4","gravatar_id":"","url":"https://api.github.com/users/1ambda","html_url":"https://github.com/1ambda","followers_url":"https://api.github.com/users/1ambda/followers","following_url":"https://api.github.com/users/1ambda/following{/other_user}","gists_url":"https://api.github.com/users/1ambda/gists{/gist_id}","starred_url":"https://api.github.com/users/1ambda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/1ambda/subscriptions","organizations_url":"https://api.github.com/users/1ambda/orgs","repos_url":"https://api.github.com/users/1ambda/repos","events_url":"https://api.github.com/users/1ambda/events{/privacy}","received_events_url":"https://api.github.com/users/1ambda/received_events","type":"User","site_admin":false},"body":"### What is this PR for?\r\n\r\nSometimes I can see manually written error handler and it's repeated again and again.\r\nEven sometimes I can see missing 401 (unauthorized error) handler. So I propose here generalizing error handler for frontend. \r\n\r\n### What type of PR is it?\r\n[Improvement | Refactoring]\r\n\r\n### What is the Jira issue?\r\n\r\n[ZEPPELIN-2920](https://issues.apache.org/jira/browse/ZEPPELIN-2920)\r\n\r\n### How should this be tested?\r\n\r\nAdd `error-handler.service.test.js` and CI will test it.\r\nIf you can test manually, u can easily reproduce errornous respsone by toggling offline in chrome developer tool like. \r\n\r\n![image](https://user-images.githubusercontent.com/4968473/30199834-6534160a-94af-11e7-9685-719b74e9fa50.png)\r\n\r\n\r\n### Questions:\r\n* Does the licenses files need update? - NO\r\n* Is there breaking changes for older versions? - NO\r\n* Does this needs documentation? - NO\r\n","created_at":"2017-09-08T07:04:59Z","updated_at":"2017-09-08T07:04:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/apache/zeppelin/pulls/2573/commits","review_comments_url":"https://api.github.com/repos/apache/zeppelin/pulls/2573/comments","review_comment_url":"https://api.github.com/repos/apache/zeppelin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/zeppelin/issues/2573/comments","statuses_url":"https://api.github.com/repos/apache/zeppelin/statuses/1a8142bfb834b6abdc80e73055f2cbd0166eaab7","head":{"label":"1ambda:ZEPPELIN-2920/refactor-add-error-handler-service","ref":"ZEPPELIN-2920/refactor-add-error-handler-service","sha":"1a8142bfb834b6abdc80e73055f2cbd0166eaab7","user":{"login":"1ambda","id":4968473,"avatar_url":"https://avatars3.githubusercontent.com/u/4968473?v=4","gravatar_id":"","url":"https://api.github.com/users/1ambda","html_url":"https://github.com/1ambda","followers_url":"https://api.github.com/users/1ambda/followers","following_url":"https://api.github.com/users/1ambda/following{/other_user}","gists_url":"https://api.github.com/users/1ambda/gists{/gist_id}","starred_url":"https://api.github.com/users/1ambda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/1ambda/subscriptions","organizations_url":"https://api.github.com/users/1ambda/orgs","repos_url":"https://api.github.com/users/1ambda/repos","events_url":"https://api.github.com/users/1ambda/events{/privacy}","received_events_url":"https://api.github.com/users/1ambda/received_events","type":"User","site_admin":false},"repo":{"id":66360806,"name":"zeppelin","full_name":"1ambda/zeppelin","owner":{"login":"1ambda","id":4968473,"avatar_url":"https://avatars3.githubusercontent.com/u/4968473?v=4","gravatar_id":"","url":"https://api.github.com/users/1ambda","html_url":"https://github.com/1ambda","followers_url":"https://api.github.com/users/1ambda/followers","following_url":"https://api.github.com/users/1ambda/following{/other_user}","gists_url":"https://api.github.com/users/1ambda/gists{/gist_id}","starred_url":"https://api.github.com/users/1ambda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/1ambda/subscriptions","organizations_url":"https://api.github.com/users/1ambda/orgs","repos_url":"https://api.github.com/users/1ambda/repos","events_url":"https://api.github.com/users/1ambda/events{/privacy}","received_events_url":"https://api.github.com/users/1ambda/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/1ambda/zeppelin","description":"Mirror of Apache Zeppelin","fork":true,"url":"https://api.github.com/repos/1ambda/zeppelin","forks_url":"https://api.github.com/repos/1ambda/zeppelin/forks","keys_url":"https://api.github.com/repos/1ambda/zeppelin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/1ambda/zeppelin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/1ambda/zeppelin/teams","hooks_url":"https://api.github.com/repos/1ambda/zeppelin/hooks","issue_events_url":"https://api.github.com/repos/1ambda/zeppelin/issues/events{/number}","events_url":"https://api.github.com/repos/1ambda/zeppelin/events","assignees_url":"https://api.github.com/repos/1ambda/zeppelin/assignees{/user}","branches_url":"https://api.github.com/repos/1ambda/zeppelin/branches{/branch}","tags_url":"https://api.github.com/repos/1ambda/zeppelin/tags","blobs_url":"https://api.github.com/repos/1ambda/zeppelin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/1ambda/zeppelin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/1ambda/zeppelin/git/refs{/sha}","trees_url":"https://api.github.com/repos/1ambda/zeppelin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/1ambda/zeppelin/statuses/{sha}","languages_url":"https://api.github.com/repos/1ambda/zeppelin/languages","stargazers_url":"https://api.github.com/repos/1ambda/zeppelin/stargazers","contributors_url":"https://api.github.com/repos/1ambda/zeppelin/contributors","subscribers_url":"https://api.github.com/repos/1ambda/zeppelin/subscribers","subscription_url":"https://api.github.com/repos/1ambda/zeppelin/subscription","commits_url":"https://api.github.com/repos/1ambda/zeppelin/commits{/sha}","git_commits_url":"https://api.github.com/repos/1ambda/zeppelin/git/commits{/sha}","comments_url":"https://api.github.com/repos/1ambda/zeppelin/comments{/number}","issue_comment_url":"https://api.github.com/repos/1ambda/zeppelin/issues/comments{/number}","contents_url":"https://api.github.com/repos/1ambda/zeppelin/contents/{+path}","compare_url":"https://api.github.com/repos/1ambda/zeppelin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/1ambda/zeppelin/merges","archive_url":"https://api.github.com/repos/1ambda/zeppelin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/1ambda/zeppelin/downloads","issues_url":"https://api.github.com/repos/1ambda/zeppelin/issues{/number}","pulls_url":"https://api.github.com/repos/1ambda/zeppelin/pulls{/number}","milestones_url":"https://api.github.com/repos/1ambda/zeppelin/milestones{/number}","notifications_url":"https://api.github.com/repos/1ambda/zeppelin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/1ambda/zeppelin/labels{/name}","releases_url":"https://api.github.com/repos/1ambda/zeppelin/releases{/id}","deployments_url":"https://api.github.com/repos/1ambda/zeppelin/deployments","created_at":"2016-08-23T11:23:11Z","updated_at":"2016-08-23T11:23:14Z","pushed_at":"2017-09-08T07:00:50Z","git_url":"git://github.com/1ambda/zeppelin.git","ssh_url":"git@github.com:1ambda/zeppelin.git","clone_url":"https://github.com/1ambda/zeppelin.git","svn_url":"https://github.com/1ambda/zeppelin","homepage":"","size":64000,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"apache:master","ref":"master","sha":"bf7ada0e28a830cc7eb9a42874734589a19c3f6b","user":{"login":"apache","id":47359,"avatar_url":"https://avatars0.githubusercontent.com/u/47359?v=4","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":32848140,"name":"zeppelin","full_name":"apache/zeppelin","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars0.githubusercontent.com/u/47359?v=4","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/zeppelin","description":"Mirror of Apache Zeppelin","fork":false,"url":"https://api.github.com/repos/apache/zeppelin","forks_url":"https://api.github.com/repos/apache/zeppelin/forks","keys_url":"https://api.github.com/repos/apache/zeppelin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/zeppelin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/zeppelin/teams","hooks_url":"https://api.github.com/repos/apache/zeppelin/hooks","issue_events_url":"https://api.github.com/repos/apache/zeppelin/issues/events{/number}","events_url":"https://api.github.com/repos/apache/zeppelin/events","assignees_url":"https://api.github.com/repos/apache/zeppelin/assignees{/user}","branches_url":"https://api.github.com/repos/apache/zeppelin/branches{/branch}","tags_url":"https://api.github.com/repos/apache/zeppelin/tags","blobs_url":"https://api.github.com/repos/apache/zeppelin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/zeppelin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/zeppelin/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/zeppelin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/zeppelin/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/zeppelin/languages","stargazers_url":"https://api.github.com/repos/apache/zeppelin/stargazers","contributors_url":"https://api.github.com/repos/apache/zeppelin/contributors","subscribers_url":"https://api.github.com/repos/apache/zeppelin/subscribers","subscription_url":"https://api.github.com/repos/apache/zeppelin/subscription","commits_url":"https://api.github.com/repos/apache/zeppelin/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/zeppelin/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/zeppelin/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/zeppelin/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/zeppelin/contents/{+path}","compare_url":"https://api.github.com/repos/apache/zeppelin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/zeppelin/merges","archive_url":"https://api.github.com/repos/apache/zeppelin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/zeppelin/downloads","issues_url":"https://api.github.com/repos/apache/zeppelin/issues{/number}","pulls_url":"https://api.github.com/repos/apache/zeppelin/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/zeppelin/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/zeppelin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/zeppelin/labels{/name}","releases_url":"https://api.github.com/repos/apache/zeppelin/releases{/id}","deployments_url":"https://api.github.com/repos/apache/zeppelin/deployments","created_at":"2015-03-25T07:00:06Z","updated_at":"2017-09-07T12:34:23Z","pushed_at":"2017-09-08T07:03:40Z","git_url":"git://github.com/apache/zeppelin.git","ssh_url":"git@github.com:apache/zeppelin.git","clone_url":"https://github.com/apache/zeppelin.git","svn_url":"https://github.com/apache/zeppelin","homepage":"","size":60855,"stargazers_count":3099,"watchers_count":3099,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1586,"mirror_url":"git://git.apache.org/incubator-zeppelin.git","open_issues_count":150,"forks":1586,"open_issues":150,"watchers":3099,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/zeppelin/pulls/2573"},"html":{"href":"https://github.com/apache/zeppelin/pull/2573"},"issue":{"href":"https://api.github.com/repos/apache/zeppelin/issues/2573"},"comments":{"href":"https://api.github.com/repos/apache/zeppelin/issues/2573/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/zeppelin/pulls/2573/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/zeppelin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/zeppelin/pulls/2573/commits"},"statuses":{"href":"https://api.github.com/repos/apache/zeppelin/statuses/1a8142bfb834b6abdc80e73055f2cbd0166eaab7"}},"author_association":"MEMBER","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":2,"additions":176,"deletions":127,"changed_files":8}}
{"actor":{"display_login":"1ambda"}}