{"action":"closed","number":2062,"pull_request":{"url":"https://api.github.com/repos/hyperledger/fabric/pulls/2062","id":75566481,"html_url":"https://github.com/hyperledger/fabric/pull/2062","diff_url":"https://github.com/hyperledger/fabric/pull/2062.diff","patch_url":"https://github.com/hyperledger/fabric/pull/2062.patch","issue_url":"https://api.github.com/repos/hyperledger/fabric/issues/2062","number":2062,"state":"closed","locked":false,"title":"Fixed issue #1824","user":{"login":"jeronimoirazabal","id":1755729,"avatar_url":"https://avatars.githubusercontent.com/u/1755729?v=3","gravatar_id":"","url":"https://api.github.com/users/jeronimoirazabal","html_url":"https://github.com/jeronimoirazabal","followers_url":"https://api.github.com/users/jeronimoirazabal/followers","following_url":"https://api.github.com/users/jeronimoirazabal/following{/other_user}","gists_url":"https://api.github.com/users/jeronimoirazabal/gists{/gist_id}","starred_url":"https://api.github.com/users/jeronimoirazabal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeronimoirazabal/subscriptions","organizations_url":"https://api.github.com/users/jeronimoirazabal/orgs","repos_url":"https://api.github.com/users/jeronimoirazabal/repos","events_url":"https://api.github.com/users/jeronimoirazabal/events{/privacy}","received_events_url":"https://api.github.com/users/jeronimoirazabal/received_events","type":"User","site_admin":false},"body":"Registration flow wasn't taking into account failures while retrieving certificates from CAs. As a result, whenever a peer failed to get the TLS certificate it ended up in a bad state (not completely registered and not able to be initialized).\r\n\r\n## Description\r\nAs part of this PR, a refactoring of the hierarchy of node, peer, client and validator nodes was performed, in order to have validation logic at the highest level of abstraction (node).\r\nTo prevent nodes from ending up in a bad state due to a failure, all the functions in charge of retrieving certificates were made idempotent by taking into account whether the corresponding certificate was already retrieved and stored.\r\n\r\n## Motivation and Context\r\nFixes #1824\r\n\r\n## How Has This Been Tested?\r\nThis PR does not require additional test cases as no new functionality was introduced.\r\n- Unit tests have been run without errors.\r\n- Behave tests have been run without errors.\r\n- Node.js tests have been run without errors (compared with master branch)\r\n\r\n## Checklist:\r\n- [x] I have added a [Signed-off-by](https://github.com/hyperledger/fabric/blob/master/CONTRIBUTING.md#legal-stuff).\r\n- [x] This change requires no new documentation.\r\n- [x] This change requires no new tests.\r\n- [x] I have run [golint](https://github.com/golang/lint) and have fixed valid warnings in code I have added or modified.\r\n\r\nSigned-off-by: Jeronimo Irazabal <jeronimo.irazabal@gmail.com> / <iraza@ar.ibm.com>","created_at":"2016-06-28T23:21:39Z","updated_at":"2016-07-14T21:30:19Z","closed_at":"2016-07-14T21:30:19Z","merged_at":"2016-07-14T21:30:19Z","merge_commit_sha":"e3a41644412fb2acc775ee3c062323e6e708e38d","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/hyperledger/fabric/pulls/2062/commits","review_comments_url":"https://api.github.com/repos/hyperledger/fabric/pulls/2062/comments","review_comment_url":"https://api.github.com/repos/hyperledger/fabric/pulls/comments{/number}","comments_url":"https://api.github.com/repos/hyperledger/fabric/issues/2062/comments","statuses_url":"https://api.github.com/repos/hyperledger/fabric/statuses/0753194ded977554e21cd7383eb7569609098a36","head":{"label":"jeronimoirazabal:fixIssue1824","ref":"fixIssue1824","sha":"0753194ded977554e21cd7383eb7569609098a36","user":{"login":"jeronimoirazabal","id":1755729,"avatar_url":"https://avatars.githubusercontent.com/u/1755729?v=3","gravatar_id":"","url":"https://api.github.com/users/jeronimoirazabal","html_url":"https://github.com/jeronimoirazabal","followers_url":"https://api.github.com/users/jeronimoirazabal/followers","following_url":"https://api.github.com/users/jeronimoirazabal/following{/other_user}","gists_url":"https://api.github.com/users/jeronimoirazabal/gists{/gist_id}","starred_url":"https://api.github.com/users/jeronimoirazabal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeronimoirazabal/subscriptions","organizations_url":"https://api.github.com/users/jeronimoirazabal/orgs","repos_url":"https://api.github.com/users/jeronimoirazabal/repos","events_url":"https://api.github.com/users/jeronimoirazabal/events{/privacy}","received_events_url":"https://api.github.com/users/jeronimoirazabal/received_events","type":"User","site_admin":false},"repo":{"id":58483762,"name":"fabric","full_name":"jeronimoirazabal/fabric","owner":{"login":"jeronimoirazabal","id":1755729,"avatar_url":"https://avatars.githubusercontent.com/u/1755729?v=3","gravatar_id":"","url":"https://api.github.com/users/jeronimoirazabal","html_url":"https://github.com/jeronimoirazabal","followers_url":"https://api.github.com/users/jeronimoirazabal/followers","following_url":"https://api.github.com/users/jeronimoirazabal/following{/other_user}","gists_url":"https://api.github.com/users/jeronimoirazabal/gists{/gist_id}","starred_url":"https://api.github.com/users/jeronimoirazabal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeronimoirazabal/subscriptions","organizations_url":"https://api.github.com/users/jeronimoirazabal/orgs","repos_url":"https://api.github.com/users/jeronimoirazabal/repos","events_url":"https://api.github.com/users/jeronimoirazabal/events{/privacy}","received_events_url":"https://api.github.com/users/jeronimoirazabal/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jeronimoirazabal/fabric","description":"Fabric is a blockchain project in Incubation proposed to the community and documented at https://goo.gl/RYQZ5N.  Information on what Incubation entails can be found in the Hyperledger Project Lifecycle document (https://goo.gl/4edNRc)","fork":true,"url":"https://api.github.com/repos/jeronimoirazabal/fabric","forks_url":"https://api.github.com/repos/jeronimoirazabal/fabric/forks","keys_url":"https://api.github.com/repos/jeronimoirazabal/fabric/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jeronimoirazabal/fabric/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jeronimoirazabal/fabric/teams","hooks_url":"https://api.github.com/repos/jeronimoirazabal/fabric/hooks","issue_events_url":"https://api.github.com/repos/jeronimoirazabal/fabric/issues/events{/number}","events_url":"https://api.github.com/repos/jeronimoirazabal/fabric/events","assignees_url":"https://api.github.com/repos/jeronimoirazabal/fabric/assignees{/user}","branches_url":"https://api.github.com/repos/jeronimoirazabal/fabric/branches{/branch}","tags_url":"https://api.github.com/repos/jeronimoirazabal/fabric/tags","blobs_url":"https://api.github.com/repos/jeronimoirazabal/fabric/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jeronimoirazabal/fabric/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jeronimoirazabal/fabric/git/refs{/sha}","trees_url":"https://api.github.com/repos/jeronimoirazabal/fabric/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jeronimoirazabal/fabric/statuses/{sha}","languages_url":"https://api.github.com/repos/jeronimoirazabal/fabric/languages","stargazers_url":"https://api.github.com/repos/jeronimoirazabal/fabric/stargazers","contributors_url":"https://api.github.com/repos/jeronimoirazabal/fabric/contributors","subscribers_url":"https://api.github.com/repos/jeronimoirazabal/fabric/subscribers","subscription_url":"https://api.github.com/repos/jeronimoirazabal/fabric/subscription","commits_url":"https://api.github.com/repos/jeronimoirazabal/fabric/commits{/sha}","git_commits_url":"https://api.github.com/repos/jeronimoirazabal/fabric/git/commits{/sha}","comments_url":"https://api.github.com/repos/jeronimoirazabal/fabric/comments{/number}","issue_comment_url":"https://api.github.com/repos/jeronimoirazabal/fabric/issues/comments{/number}","contents_url":"https://api.github.com/repos/jeronimoirazabal/fabric/contents/{+path}","compare_url":"https://api.github.com/repos/jeronimoirazabal/fabric/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jeronimoirazabal/fabric/merges","archive_url":"https://api.github.com/repos/jeronimoirazabal/fabric/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jeronimoirazabal/fabric/downloads","issues_url":"https://api.github.com/repos/jeronimoirazabal/fabric/issues{/number}","pulls_url":"https://api.github.com/repos/jeronimoirazabal/fabric/pulls{/number}","milestones_url":"https://api.github.com/repos/jeronimoirazabal/fabric/milestones{/number}","notifications_url":"https://api.github.com/repos/jeronimoirazabal/fabric/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jeronimoirazabal/fabric/labels{/name}","releases_url":"https://api.github.com/repos/jeronimoirazabal/fabric/releases{/id}","deployments_url":"https://api.github.com/repos/jeronimoirazabal/fabric/deployments","created_at":"2016-05-10T18:16:48Z","updated_at":"2016-05-10T18:16:50Z","pushed_at":"2016-07-14T18:03:43Z","git_url":"git://github.com/jeronimoirazabal/fabric.git","ssh_url":"git@github.com:jeronimoirazabal/fabric.git","clone_url":"https://github.com/jeronimoirazabal/fabric.git","svn_url":"https://github.com/jeronimoirazabal/fabric","homepage":"","size":45519,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"hyperledger:master","ref":"master","sha":"6dbeac0faf892baddd3c4c83a3199092dc5ed7f6","user":{"login":"hyperledger","id":7657900,"avatar_url":"https://avatars.githubusercontent.com/u/7657900?v=3","gravatar_id":"","url":"https://api.github.com/users/hyperledger","html_url":"https://github.com/hyperledger","followers_url":"https://api.github.com/users/hyperledger/followers","following_url":"https://api.github.com/users/hyperledger/following{/other_user}","gists_url":"https://api.github.com/users/hyperledger/gists{/gist_id}","starred_url":"https://api.github.com/users/hyperledger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hyperledger/subscriptions","organizations_url":"https://api.github.com/users/hyperledger/orgs","repos_url":"https://api.github.com/users/hyperledger/repos","events_url":"https://api.github.com/users/hyperledger/events{/privacy}","received_events_url":"https://api.github.com/users/hyperledger/received_events","type":"Organization","site_admin":false},"repo":{"id":42975662,"name":"fabric","full_name":"hyperledger/fabric","owner":{"login":"hyperledger","id":7657900,"avatar_url":"https://avatars.githubusercontent.com/u/7657900?v=3","gravatar_id":"","url":"https://api.github.com/users/hyperledger","html_url":"https://github.com/hyperledger","followers_url":"https://api.github.com/users/hyperledger/followers","following_url":"https://api.github.com/users/hyperledger/following{/other_user}","gists_url":"https://api.github.com/users/hyperledger/gists{/gist_id}","starred_url":"https://api.github.com/users/hyperledger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hyperledger/subscriptions","organizations_url":"https://api.github.com/users/hyperledger/orgs","repos_url":"https://api.github.com/users/hyperledger/repos","events_url":"https://api.github.com/users/hyperledger/events{/privacy}","received_events_url":"https://api.github.com/users/hyperledger/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/hyperledger/fabric","description":"Fabric is a blockchain project in Incubation proposed to the community and documented at https://goo.gl/RYQZ5N.  Information on what Incubation entails can be found in the Hyperledger Project Lifecycle document (https://goo.gl/4edNRc)","fork":false,"url":"https://api.github.com/repos/hyperledger/fabric","forks_url":"https://api.github.com/repos/hyperledger/fabric/forks","keys_url":"https://api.github.com/repos/hyperledger/fabric/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hyperledger/fabric/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hyperledger/fabric/teams","hooks_url":"https://api.github.com/repos/hyperledger/fabric/hooks","issue_events_url":"https://api.github.com/repos/hyperledger/fabric/issues/events{/number}","events_url":"https://api.github.com/repos/hyperledger/fabric/events","assignees_url":"https://api.github.com/repos/hyperledger/fabric/assignees{/user}","branches_url":"https://api.github.com/repos/hyperledger/fabric/branches{/branch}","tags_url":"https://api.github.com/repos/hyperledger/fabric/tags","blobs_url":"https://api.github.com/repos/hyperledger/fabric/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hyperledger/fabric/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hyperledger/fabric/git/refs{/sha}","trees_url":"https://api.github.com/repos/hyperledger/fabric/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hyperledger/fabric/statuses/{sha}","languages_url":"https://api.github.com/repos/hyperledger/fabric/languages","stargazers_url":"https://api.github.com/repos/hyperledger/fabric/stargazers","contributors_url":"https://api.github.com/repos/hyperledger/fabric/contributors","subscribers_url":"https://api.github.com/repos/hyperledger/fabric/subscribers","subscription_url":"https://api.github.com/repos/hyperledger/fabric/subscription","commits_url":"https://api.github.com/repos/hyperledger/fabric/commits{/sha}","git_commits_url":"https://api.github.com/repos/hyperledger/fabric/git/commits{/sha}","comments_url":"https://api.github.com/repos/hyperledger/fabric/comments{/number}","issue_comment_url":"https://api.github.com/repos/hyperledger/fabric/issues/comments{/number}","contents_url":"https://api.github.com/repos/hyperledger/fabric/contents/{+path}","compare_url":"https://api.github.com/repos/hyperledger/fabric/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hyperledger/fabric/merges","archive_url":"https://api.github.com/repos/hyperledger/fabric/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hyperledger/fabric/downloads","issues_url":"https://api.github.com/repos/hyperledger/fabric/issues{/number}","pulls_url":"https://api.github.com/repos/hyperledger/fabric/pulls{/number}","milestones_url":"https://api.github.com/repos/hyperledger/fabric/milestones{/number}","notifications_url":"https://api.github.com/repos/hyperledger/fabric/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hyperledger/fabric/labels{/name}","releases_url":"https://api.github.com/repos/hyperledger/fabric/releases{/id}","deployments_url":"https://api.github.com/repos/hyperledger/fabric/deployments","created_at":"2015-09-23T03:17:14Z","updated_at":"2016-07-14T08:39:58Z","pushed_at":"2016-07-14T21:30:19Z","git_url":"git://github.com/hyperledger/fabric.git","ssh_url":"git@github.com:hyperledger/fabric.git","clone_url":"https://github.com/hyperledger/fabric.git","svn_url":"https://github.com/hyperledger/fabric","homepage":"","size":89143,"stargazers_count":929,"watchers_count":929,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":889,"mirror_url":null,"open_issues_count":411,"forks":889,"open_issues":411,"watchers":929,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/hyperledger/fabric/pulls/2062"},"html":{"href":"https://github.com/hyperledger/fabric/pull/2062"},"issue":{"href":"https://api.github.com/repos/hyperledger/fabric/issues/2062"},"comments":{"href":"https://api.github.com/repos/hyperledger/fabric/issues/2062/comments"},"review_comments":{"href":"https://api.github.com/repos/hyperledger/fabric/pulls/2062/comments"},"review_comment":{"href":"https://api.github.com/repos/hyperledger/fabric/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/hyperledger/fabric/pulls/2062/commits"},"statuses":{"href":"https://api.github.com/repos/hyperledger/fabric/statuses/0753194ded977554e21cd7383eb7569609098a36"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"srderson","id":4872087,"avatar_url":"https://avatars.githubusercontent.com/u/4872087?v=3","gravatar_id":"","url":"https://api.github.com/users/srderson","html_url":"https://github.com/srderson","followers_url":"https://api.github.com/users/srderson/followers","following_url":"https://api.github.com/users/srderson/following{/other_user}","gists_url":"https://api.github.com/users/srderson/gists{/gist_id}","starred_url":"https://api.github.com/users/srderson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srderson/subscriptions","organizations_url":"https://api.github.com/users/srderson/orgs","repos_url":"https://api.github.com/users/srderson/repos","events_url":"https://api.github.com/users/srderson/events{/privacy}","received_events_url":"https://api.github.com/users/srderson/received_events","type":"User","site_admin":false},"comments":11,"review_comments":7,"commits":10,"additions":250,"deletions":159,"changed_files":12}}
{"actor":{"display_login":"srderson"}}