{"action":"opened","number":1116,"pull_request":{"url":"https://api.github.com/repos/digitalrebar/core/pulls/1116","id":63090920,"html_url":"https://github.com/digitalrebar/core/pull/1116","diff_url":"https://github.com/digitalrebar/core/pull/1116.diff","patch_url":"https://github.com/digitalrebar/core/pull/1116.patch","issue_url":"https://api.github.com/repos/digitalrebar/core/issues/1116","number":1116,"state":"open","locked":false,"title":"DO NOT MERGE: Centralize event handling, and expose it via API.","user":{"login":"VictorLowther","id":770578,"avatar_url":"https://avatars.githubusercontent.com/u/770578?v=3","gravatar_id":"","url":"https://api.github.com/users/VictorLowther","html_url":"https://github.com/VictorLowther","followers_url":"https://api.github.com/users/VictorLowther/followers","following_url":"https://api.github.com/users/VictorLowther/following{/other_user}","gists_url":"https://api.github.com/users/VictorLowther/gists{/gist_id}","starred_url":"https://api.github.com/users/VictorLowther/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/VictorLowther/subscriptions","organizations_url":"https://api.github.com/users/VictorLowther/orgs","repos_url":"https://api.github.com/users/VictorLowther/repos","events_url":"https://api.github.com/users/VictorLowther/events{/privacy}","received_events_url":"https://api.github.com/users/VictorLowther/received_events","type":"User","site_admin":false},"body":"This moves role callbacks from being handled via method dispatch with\r\nsubclass-overridable methods to a centralized event dispatching system,\r\nand updates the in-core classes to produce and consume the appropriate\r\nevents.\r\n\r\nImplementation-wise, the code is set up to handle registering event\r\nsinks that will recieve events, and event selectors that handle\r\nselecting events that a given sink is interested in.  API endpoints for\r\nevent sinks and selectors have been created at the expected locations.\r\n\r\nFor now, the only event sink we know how to handle is the in-process\r\nendpoint (named 'inproc://'), and all roles in the core that used the\r\nmethod-based event handling scheme have been updated to register the\r\nappropriate selectors at barclamp import time.\r\n\r\nBy adding an appropriate external endpoint handler and nailing down\r\nexactly what we expect a sink to handle in terms of RPCs or pub/sub, we\r\ncan do away with forcing roles that need custom behaviour to live in the\r\nsame process space as the core.\r\n\r\nThis also paves the way for adding auditing events and other useful things.\r\n\r\nThis is still a work-in-progress -- the external barclamps would need to be updated to use this framework, and I am looking for comments and feedback.","created_at":"2016-03-16T16:07:53Z","updated_at":"2016-03-16T16:07:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/digitalrebar/core/pulls/1116/commits","review_comments_url":"https://api.github.com/repos/digitalrebar/core/pulls/1116/comments","review_comment_url":"https://api.github.com/repos/digitalrebar/core/pulls/comments{/number}","comments_url":"https://api.github.com/repos/digitalrebar/core/issues/1116/comments","statuses_url":"https://api.github.com/repos/digitalrebar/core/statuses/bf36dedadf793f28faa5e52f4dffca5af304c6fd","head":{"label":"digitalrebar:rework-callback-handling-into-a-real-event-handling-system","ref":"rework-callback-handling-into-a-real-event-handling-system","sha":"bf36dedadf793f28faa5e52f4dffca5af304c6fd","user":{"login":"digitalrebar","id":13814120,"avatar_url":"https://avatars.githubusercontent.com/u/13814120?v=3","gravatar_id":"","url":"https://api.github.com/users/digitalrebar","html_url":"https://github.com/digitalrebar","followers_url":"https://api.github.com/users/digitalrebar/followers","following_url":"https://api.github.com/users/digitalrebar/following{/other_user}","gists_url":"https://api.github.com/users/digitalrebar/gists{/gist_id}","starred_url":"https://api.github.com/users/digitalrebar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/digitalrebar/subscriptions","organizations_url":"https://api.github.com/users/digitalrebar/orgs","repos_url":"https://api.github.com/users/digitalrebar/repos","events_url":"https://api.github.com/users/digitalrebar/events{/privacy}","received_events_url":"https://api.github.com/users/digitalrebar/received_events","type":"Organization","site_admin":false},"repo":{"id":15835387,"name":"core","full_name":"digitalrebar/core","owner":{"login":"digitalrebar","id":13814120,"avatar_url":"https://avatars.githubusercontent.com/u/13814120?v=3","gravatar_id":"","url":"https://api.github.com/users/digitalrebar","html_url":"https://github.com/digitalrebar","followers_url":"https://api.github.com/users/digitalrebar/followers","following_url":"https://api.github.com/users/digitalrebar/following{/other_user}","gists_url":"https://api.github.com/users/digitalrebar/gists{/gist_id}","starred_url":"https://api.github.com/users/digitalrebar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/digitalrebar/subscriptions","organizations_url":"https://api.github.com/users/digitalrebar/orgs","repos_url":"https://api.github.com/users/digitalrebar/repos","events_url":"https://api.github.com/users/digitalrebar/events{/privacy}","received_events_url":"https://api.github.com/users/digitalrebar/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/digitalrebar/core","description":"Digital Rebar Framework and Core Infrastructure Components","fork":false,"url":"https://api.github.com/repos/digitalrebar/core","forks_url":"https://api.github.com/repos/digitalrebar/core/forks","keys_url":"https://api.github.com/repos/digitalrebar/core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/digitalrebar/core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/digitalrebar/core/teams","hooks_url":"https://api.github.com/repos/digitalrebar/core/hooks","issue_events_url":"https://api.github.com/repos/digitalrebar/core/issues/events{/number}","events_url":"https://api.github.com/repos/digitalrebar/core/events","assignees_url":"https://api.github.com/repos/digitalrebar/core/assignees{/user}","branches_url":"https://api.github.com/repos/digitalrebar/core/branches{/branch}","tags_url":"https://api.github.com/repos/digitalrebar/core/tags","blobs_url":"https://api.github.com/repos/digitalrebar/core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/digitalrebar/core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/digitalrebar/core/git/refs{/sha}","trees_url":"https://api.github.com/repos/digitalrebar/core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/digitalrebar/core/statuses/{sha}","languages_url":"https://api.github.com/repos/digitalrebar/core/languages","stargazers_url":"https://api.github.com/repos/digitalrebar/core/stargazers","contributors_url":"https://api.github.com/repos/digitalrebar/core/contributors","subscribers_url":"https://api.github.com/repos/digitalrebar/core/subscribers","subscription_url":"https://api.github.com/repos/digitalrebar/core/subscription","commits_url":"https://api.github.com/repos/digitalrebar/core/commits{/sha}","git_commits_url":"https://api.github.com/repos/digitalrebar/core/git/commits{/sha}","comments_url":"https://api.github.com/repos/digitalrebar/core/comments{/number}","issue_comment_url":"https://api.github.com/repos/digitalrebar/core/issues/comments{/number}","contents_url":"https://api.github.com/repos/digitalrebar/core/contents/{+path}","compare_url":"https://api.github.com/repos/digitalrebar/core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/digitalrebar/core/merges","archive_url":"https://api.github.com/repos/digitalrebar/core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/digitalrebar/core/downloads","issues_url":"https://api.github.com/repos/digitalrebar/core/issues{/number}","pulls_url":"https://api.github.com/repos/digitalrebar/core/pulls{/number}","milestones_url":"https://api.github.com/repos/digitalrebar/core/milestones{/number}","notifications_url":"https://api.github.com/repos/digitalrebar/core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/digitalrebar/core/labels{/name}","releases_url":"https://api.github.com/repos/digitalrebar/core/releases{/id}","deployments_url":"https://api.github.com/repos/digitalrebar/core/deployments","created_at":"2014-01-12T02:59:50Z","updated_at":"2016-03-02T16:08:35Z","pushed_at":"2016-03-16T16:05:11Z","git_url":"git://github.com/digitalrebar/core.git","ssh_url":"git@github.com:digitalrebar/core.git","clone_url":"https://github.com/digitalrebar/core.git","svn_url":"https://github.com/digitalrebar/core","homepage":"http://rebar.digital","size":50976,"stargazers_count":109,"watchers_count":109,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":46,"mirror_url":null,"open_issues_count":54,"forks":46,"open_issues":54,"watchers":109,"default_branch":"develop"}},"base":{"label":"digitalrebar:develop","ref":"develop","sha":"2901847cca97b81ac98ceb40c2769a32a67a770e","user":{"login":"digitalrebar","id":13814120,"avatar_url":"https://avatars.githubusercontent.com/u/13814120?v=3","gravatar_id":"","url":"https://api.github.com/users/digitalrebar","html_url":"https://github.com/digitalrebar","followers_url":"https://api.github.com/users/digitalrebar/followers","following_url":"https://api.github.com/users/digitalrebar/following{/other_user}","gists_url":"https://api.github.com/users/digitalrebar/gists{/gist_id}","starred_url":"https://api.github.com/users/digitalrebar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/digitalrebar/subscriptions","organizations_url":"https://api.github.com/users/digitalrebar/orgs","repos_url":"https://api.github.com/users/digitalrebar/repos","events_url":"https://api.github.com/users/digitalrebar/events{/privacy}","received_events_url":"https://api.github.com/users/digitalrebar/received_events","type":"Organization","site_admin":false},"repo":{"id":15835387,"name":"core","full_name":"digitalrebar/core","owner":{"login":"digitalrebar","id":13814120,"avatar_url":"https://avatars.githubusercontent.com/u/13814120?v=3","gravatar_id":"","url":"https://api.github.com/users/digitalrebar","html_url":"https://github.com/digitalrebar","followers_url":"https://api.github.com/users/digitalrebar/followers","following_url":"https://api.github.com/users/digitalrebar/following{/other_user}","gists_url":"https://api.github.com/users/digitalrebar/gists{/gist_id}","starred_url":"https://api.github.com/users/digitalrebar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/digitalrebar/subscriptions","organizations_url":"https://api.github.com/users/digitalrebar/orgs","repos_url":"https://api.github.com/users/digitalrebar/repos","events_url":"https://api.github.com/users/digitalrebar/events{/privacy}","received_events_url":"https://api.github.com/users/digitalrebar/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/digitalrebar/core","description":"Digital Rebar Framework and Core Infrastructure Components","fork":false,"url":"https://api.github.com/repos/digitalrebar/core","forks_url":"https://api.github.com/repos/digitalrebar/core/forks","keys_url":"https://api.github.com/repos/digitalrebar/core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/digitalrebar/core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/digitalrebar/core/teams","hooks_url":"https://api.github.com/repos/digitalrebar/core/hooks","issue_events_url":"https://api.github.com/repos/digitalrebar/core/issues/events{/number}","events_url":"https://api.github.com/repos/digitalrebar/core/events","assignees_url":"https://api.github.com/repos/digitalrebar/core/assignees{/user}","branches_url":"https://api.github.com/repos/digitalrebar/core/branches{/branch}","tags_url":"https://api.github.com/repos/digitalrebar/core/tags","blobs_url":"https://api.github.com/repos/digitalrebar/core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/digitalrebar/core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/digitalrebar/core/git/refs{/sha}","trees_url":"https://api.github.com/repos/digitalrebar/core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/digitalrebar/core/statuses/{sha}","languages_url":"https://api.github.com/repos/digitalrebar/core/languages","stargazers_url":"https://api.github.com/repos/digitalrebar/core/stargazers","contributors_url":"https://api.github.com/repos/digitalrebar/core/contributors","subscribers_url":"https://api.github.com/repos/digitalrebar/core/subscribers","subscription_url":"https://api.github.com/repos/digitalrebar/core/subscription","commits_url":"https://api.github.com/repos/digitalrebar/core/commits{/sha}","git_commits_url":"https://api.github.com/repos/digitalrebar/core/git/commits{/sha}","comments_url":"https://api.github.com/repos/digitalrebar/core/comments{/number}","issue_comment_url":"https://api.github.com/repos/digitalrebar/core/issues/comments{/number}","contents_url":"https://api.github.com/repos/digitalrebar/core/contents/{+path}","compare_url":"https://api.github.com/repos/digitalrebar/core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/digitalrebar/core/merges","archive_url":"https://api.github.com/repos/digitalrebar/core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/digitalrebar/core/downloads","issues_url":"https://api.github.com/repos/digitalrebar/core/issues{/number}","pulls_url":"https://api.github.com/repos/digitalrebar/core/pulls{/number}","milestones_url":"https://api.github.com/repos/digitalrebar/core/milestones{/number}","notifications_url":"https://api.github.com/repos/digitalrebar/core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/digitalrebar/core/labels{/name}","releases_url":"https://api.github.com/repos/digitalrebar/core/releases{/id}","deployments_url":"https://api.github.com/repos/digitalrebar/core/deployments","created_at":"2014-01-12T02:59:50Z","updated_at":"2016-03-02T16:08:35Z","pushed_at":"2016-03-16T16:05:11Z","git_url":"git://github.com/digitalrebar/core.git","ssh_url":"git@github.com:digitalrebar/core.git","clone_url":"https://github.com/digitalrebar/core.git","svn_url":"https://github.com/digitalrebar/core","homepage":"http://rebar.digital","size":50976,"stargazers_count":109,"watchers_count":109,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":46,"mirror_url":null,"open_issues_count":54,"forks":46,"open_issues":54,"watchers":109,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/digitalrebar/core/pulls/1116"},"html":{"href":"https://github.com/digitalrebar/core/pull/1116"},"issue":{"href":"https://api.github.com/repos/digitalrebar/core/issues/1116"},"comments":{"href":"https://api.github.com/repos/digitalrebar/core/issues/1116/comments"},"review_comments":{"href":"https://api.github.com/repos/digitalrebar/core/pulls/1116/comments"},"review_comment":{"href":"https://api.github.com/repos/digitalrebar/core/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/digitalrebar/core/pulls/1116/commits"},"statuses":{"href":"https://api.github.com/repos/digitalrebar/core/statuses/bf36dedadf793f28faa5e52f4dffca5af304c6fd"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":502,"deletions":200,"changed_files":22}}