{"action":"created","comment":{"url":"https://api.github.com/repos/loomio/loomio/pulls/comments/53379547","id":53379547,"diff_hunk":"@@ -659,6 +659,15 @@\n   add_index \"organisation_visits\", [\"organisation_id\"], name: \"index_organisation_visits_on_organisation_id\", using: :btree\n   add_index \"organisation_visits\", [\"visit_id\", \"organisation_id\"], name: \"index_organisation_visits_on_visit_id_and_organisation_id\", unique: true, using: :btree\n \n+  create_table \"specifics\", force: :cascade do |t|","path":"db/schema.rb","position":4,"original_position":4,"commit_id":"490b10509f3e160a156247fe7dfdce98b97ba3fc","original_commit_id":"490b10509f3e160a156247fe7dfdce98b97ba3fc","user":{"login":"gdpelican","id":750477,"avatar_url":"https://avatars.githubusercontent.com/u/750477?v=3","gravatar_id":"","url":"https://api.github.com/users/gdpelican","html_url":"https://github.com/gdpelican","followers_url":"https://api.github.com/users/gdpelican/followers","following_url":"https://api.github.com/users/gdpelican/following{/other_user}","gists_url":"https://api.github.com/users/gdpelican/gists{/gist_id}","starred_url":"https://api.github.com/users/gdpelican/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gdpelican/subscriptions","organizations_url":"https://api.github.com/users/gdpelican/orgs","repos_url":"https://api.github.com/users/gdpelican/repos","events_url":"https://api.github.com/users/gdpelican/events{/privacy}","received_events_url":"https://api.github.com/users/gdpelican/received_events","type":"User","site_admin":false},"body":"After having a ponder, I think I've landed on 'why take away options?' Tough to future imagine what the best solution will be, but it doesn't have to be one or the other, and I think there will definitely be cases where a shared model will be more effective than a database table, and vice versa.\r\n\r\nLike, even the fact that we're respectfully clashing a bit over these two things is telling me 'aw, some authors will want to touch the schema, while others will prefer a more JSON-y approach, and that's cool.'","created_at":"2016-02-18T20:45:36Z","updated_at":"2016-02-18T20:45:36Z","html_url":"https://github.com/loomio/loomio/pull/2863#discussion_r53379547","pull_request_url":"https://api.github.com/repos/loomio/loomio/pulls/2863","_links":{"self":{"href":"https://api.github.com/repos/loomio/loomio/pulls/comments/53379547"},"html":{"href":"https://github.com/loomio/loomio/pull/2863#discussion_r53379547"},"pull_request":{"href":"https://api.github.com/repos/loomio/loomio/pulls/2863"}}},"pull_request":{"url":"https://api.github.com/repos/loomio/loomio/pulls/2863","id":55554125,"html_url":"https://github.com/loomio/loomio/pull/2863","diff_url":"https://github.com/loomio/loomio/pull/2863.diff","patch_url":"https://github.com/loomio/loomio/pull/2863.patch","issue_url":"https://api.github.com/repos/loomio/loomio/issues/2863","number":2863,"state":"open","locked":false,"title":"Plugin architecture","user":{"login":"gdpelican","id":750477,"avatar_url":"https://avatars.githubusercontent.com/u/750477?v=3","gravatar_id":"","url":"https://api.github.com/users/gdpelican","html_url":"https://github.com/gdpelican","followers_url":"https://api.github.com/users/gdpelican/followers","following_url":"https://api.github.com/users/gdpelican/following{/other_user}","gists_url":"https://api.github.com/users/gdpelican/gists{/gist_id}","starred_url":"https://api.github.com/users/gdpelican/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gdpelican/subscriptions","organizations_url":"https://api.github.com/users/gdpelican/orgs","repos_url":"https://api.github.com/users/gdpelican/repos","events_url":"https://api.github.com/users/gdpelican/events{/privacy}","received_events_url":"https://api.github.com/users/gdpelican/received_events","type":"User","site_admin":false},"body":"Alright, ready for this to have some eyes on it. Keen to hear some ideas for plugins that folks have so I can be sure that I'm accommodating at least most of them with this.\r\n\r\nCurrent capabilities include:\r\n\r\n- Enabling / disabling plugins via ENV\r\n- Adding new ruby classes\r\n- Extending existing ruby classes\r\n- Creating angular components\r\n- Attaching directives to outlets in the angular interface\r\n- Listening for arbitrary events (events are emitted whenever an Event is created, and every time a service method is called)\r\n- Adding translations\r\n- Adding new tables to the schema (I don't think I want to support modifying existing tables)\r\n\r\nBig TODO is defining custom routes within the plugin, and how to reach them via the angular components in a way that isn't terrible. (edit: I was able to figure out how to do this with the existing system, wee!)\r\n\r\nNB that this particular PR moves the webhook / slack functionality into a plugin.\r\n\r\nI'd encourage interested parties to have a peek at [the README](https://github.com/loomio/loomio/blob/plugins-effyeah/plugins/README.md) to get an idea of how creating new plugins would work.","created_at":"2016-01-10T00:01:54Z","updated_at":"2016-02-18T20:45:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"48727b1b402b1ee2ebe91d9210fbbb102e49af50","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/loomio/loomio/pulls/2863/commits","review_comments_url":"https://api.github.com/repos/loomio/loomio/pulls/2863/comments","review_comment_url":"https://api.github.com/repos/loomio/loomio/pulls/comments{/number}","comments_url":"https://api.github.com/repos/loomio/loomio/issues/2863/comments","statuses_url":"https://api.github.com/repos/loomio/loomio/statuses/490b10509f3e160a156247fe7dfdce98b97ba3fc","head":{"label":"loomio:plugins-effyeah","ref":"plugins-effyeah","sha":"490b10509f3e160a156247fe7dfdce98b97ba3fc","user":{"login":"loomio","id":1896739,"avatar_url":"https://avatars.githubusercontent.com/u/1896739?v=3","gravatar_id":"","url":"https://api.github.com/users/loomio","html_url":"https://github.com/loomio","followers_url":"https://api.github.com/users/loomio/followers","following_url":"https://api.github.com/users/loomio/following{/other_user}","gists_url":"https://api.github.com/users/loomio/gists{/gist_id}","starred_url":"https://api.github.com/users/loomio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/loomio/subscriptions","organizations_url":"https://api.github.com/users/loomio/orgs","repos_url":"https://api.github.com/users/loomio/repos","events_url":"https://api.github.com/users/loomio/events{/privacy}","received_events_url":"https://api.github.com/users/loomio/received_events","type":"Organization","site_admin":false},"repo":{"id":2731301,"name":"loomio","full_name":"loomio/loomio","owner":{"login":"loomio","id":1896739,"avatar_url":"https://avatars.githubusercontent.com/u/1896739?v=3","gravatar_id":"","url":"https://api.github.com/users/loomio","html_url":"https://github.com/loomio","followers_url":"https://api.github.com/users/loomio/followers","following_url":"https://api.github.com/users/loomio/following{/other_user}","gists_url":"https://api.github.com/users/loomio/gists{/gist_id}","starred_url":"https://api.github.com/users/loomio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/loomio/subscriptions","organizations_url":"https://api.github.com/users/loomio/orgs","repos_url":"https://api.github.com/users/loomio/repos","events_url":"https://api.github.com/users/loomio/events{/privacy}","received_events_url":"https://api.github.com/users/loomio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/loomio/loomio","description":"Loomio is an open-source web application that helps groups make better decisions together.","fork":false,"url":"https://api.github.com/repos/loomio/loomio","forks_url":"https://api.github.com/repos/loomio/loomio/forks","keys_url":"https://api.github.com/repos/loomio/loomio/keys{/key_id}","collaborators_url":"https://api.github.com/repos/loomio/loomio/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/loomio/loomio/teams","hooks_url":"https://api.github.com/repos/loomio/loomio/hooks","issue_events_url":"https://api.github.com/repos/loomio/loomio/issues/events{/number}","events_url":"https://api.github.com/repos/loomio/loomio/events","assignees_url":"https://api.github.com/repos/loomio/loomio/assignees{/user}","branches_url":"https://api.github.com/repos/loomio/loomio/branches{/branch}","tags_url":"https://api.github.com/repos/loomio/loomio/tags","blobs_url":"https://api.github.com/repos/loomio/loomio/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/loomio/loomio/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/loomio/loomio/git/refs{/sha}","trees_url":"https://api.github.com/repos/loomio/loomio/git/trees{/sha}","statuses_url":"https://api.github.com/repos/loomio/loomio/statuses/{sha}","languages_url":"https://api.github.com/repos/loomio/loomio/languages","stargazers_url":"https://api.github.com/repos/loomio/loomio/stargazers","contributors_url":"https://api.github.com/repos/loomio/loomio/contributors","subscribers_url":"https://api.github.com/repos/loomio/loomio/subscribers","subscription_url":"https://api.github.com/repos/loomio/loomio/subscription","commits_url":"https://api.github.com/repos/loomio/loomio/commits{/sha}","git_commits_url":"https://api.github.com/repos/loomio/loomio/git/commits{/sha}","comments_url":"https://api.github.com/repos/loomio/loomio/comments{/number}","issue_comment_url":"https://api.github.com/repos/loomio/loomio/issues/comments{/number}","contents_url":"https://api.github.com/repos/loomio/loomio/contents/{+path}","compare_url":"https://api.github.com/repos/loomio/loomio/compare/{base}...{head}","merges_url":"https://api.github.com/repos/loomio/loomio/merges","archive_url":"https://api.github.com/repos/loomio/loomio/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/loomio/loomio/downloads","issues_url":"https://api.github.com/repos/loomio/loomio/issues{/number}","pulls_url":"https://api.github.com/repos/loomio/loomio/pulls{/number}","milestones_url":"https://api.github.com/repos/loomio/loomio/milestones{/number}","notifications_url":"https://api.github.com/repos/loomio/loomio/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/loomio/loomio/labels{/name}","releases_url":"https://api.github.com/repos/loomio/loomio/releases{/id}","deployments_url":"https://api.github.com/repos/loomio/loomio/deployments","created_at":"2011-11-08T03:27:12Z","updated_at":"2016-02-18T16:25:43Z","pushed_at":"2016-02-18T19:52:57Z","git_url":"git://github.com/loomio/loomio.git","ssh_url":"git@github.com:loomio/loomio.git","clone_url":"https://github.com/loomio/loomio.git","svn_url":"https://github.com/loomio/loomio","homepage":"www.loomio.org","size":151857,"stargazers_count":1112,"watchers_count":1112,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":409,"mirror_url":null,"open_issues_count":33,"forks":409,"open_issues":33,"watchers":1112,"default_branch":"master"}},"base":{"label":"loomio:master","ref":"master","sha":"10cb8c1b04a06ce820ecdfa39fa0980075695156","user":{"login":"loomio","id":1896739,"avatar_url":"https://avatars.githubusercontent.com/u/1896739?v=3","gravatar_id":"","url":"https://api.github.com/users/loomio","html_url":"https://github.com/loomio","followers_url":"https://api.github.com/users/loomio/followers","following_url":"https://api.github.com/users/loomio/following{/other_user}","gists_url":"https://api.github.com/users/loomio/gists{/gist_id}","starred_url":"https://api.github.com/users/loomio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/loomio/subscriptions","organizations_url":"https://api.github.com/users/loomio/orgs","repos_url":"https://api.github.com/users/loomio/repos","events_url":"https://api.github.com/users/loomio/events{/privacy}","received_events_url":"https://api.github.com/users/loomio/received_events","type":"Organization","site_admin":false},"repo":{"id":2731301,"name":"loomio","full_name":"loomio/loomio","owner":{"login":"loomio","id":1896739,"avatar_url":"https://avatars.githubusercontent.com/u/1896739?v=3","gravatar_id":"","url":"https://api.github.com/users/loomio","html_url":"https://github.com/loomio","followers_url":"https://api.github.com/users/loomio/followers","following_url":"https://api.github.com/users/loomio/following{/other_user}","gists_url":"https://api.github.com/users/loomio/gists{/gist_id}","starred_url":"https://api.github.com/users/loomio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/loomio/subscriptions","organizations_url":"https://api.github.com/users/loomio/orgs","repos_url":"https://api.github.com/users/loomio/repos","events_url":"https://api.github.com/users/loomio/events{/privacy}","received_events_url":"https://api.github.com/users/loomio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/loomio/loomio","description":"Loomio is an open-source web application that helps groups make better decisions together.","fork":false,"url":"https://api.github.com/repos/loomio/loomio","forks_url":"https://api.github.com/repos/loomio/loomio/forks","keys_url":"https://api.github.com/repos/loomio/loomio/keys{/key_id}","collaborators_url":"https://api.github.com/repos/loomio/loomio/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/loomio/loomio/teams","hooks_url":"https://api.github.com/repos/loomio/loomio/hooks","issue_events_url":"https://api.github.com/repos/loomio/loomio/issues/events{/number}","events_url":"https://api.github.com/repos/loomio/loomio/events","assignees_url":"https://api.github.com/repos/loomio/loomio/assignees{/user}","branches_url":"https://api.github.com/repos/loomio/loomio/branches{/branch}","tags_url":"https://api.github.com/repos/loomio/loomio/tags","blobs_url":"https://api.github.com/repos/loomio/loomio/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/loomio/loomio/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/loomio/loomio/git/refs{/sha}","trees_url":"https://api.github.com/repos/loomio/loomio/git/trees{/sha}","statuses_url":"https://api.github.com/repos/loomio/loomio/statuses/{sha}","languages_url":"https://api.github.com/repos/loomio/loomio/languages","stargazers_url":"https://api.github.com/repos/loomio/loomio/stargazers","contributors_url":"https://api.github.com/repos/loomio/loomio/contributors","subscribers_url":"https://api.github.com/repos/loomio/loomio/subscribers","subscription_url":"https://api.github.com/repos/loomio/loomio/subscription","commits_url":"https://api.github.com/repos/loomio/loomio/commits{/sha}","git_commits_url":"https://api.github.com/repos/loomio/loomio/git/commits{/sha}","comments_url":"https://api.github.com/repos/loomio/loomio/comments{/number}","issue_comment_url":"https://api.github.com/repos/loomio/loomio/issues/comments{/number}","contents_url":"https://api.github.com/repos/loomio/loomio/contents/{+path}","compare_url":"https://api.github.com/repos/loomio/loomio/compare/{base}...{head}","merges_url":"https://api.github.com/repos/loomio/loomio/merges","archive_url":"https://api.github.com/repos/loomio/loomio/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/loomio/loomio/downloads","issues_url":"https://api.github.com/repos/loomio/loomio/issues{/number}","pulls_url":"https://api.github.com/repos/loomio/loomio/pulls{/number}","milestones_url":"https://api.github.com/repos/loomio/loomio/milestones{/number}","notifications_url":"https://api.github.com/repos/loomio/loomio/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/loomio/loomio/labels{/name}","releases_url":"https://api.github.com/repos/loomio/loomio/releases{/id}","deployments_url":"https://api.github.com/repos/loomio/loomio/deployments","created_at":"2011-11-08T03:27:12Z","updated_at":"2016-02-18T16:25:43Z","pushed_at":"2016-02-18T19:52:57Z","git_url":"git://github.com/loomio/loomio.git","ssh_url":"git@github.com:loomio/loomio.git","clone_url":"https://github.com/loomio/loomio.git","svn_url":"https://github.com/loomio/loomio","homepage":"www.loomio.org","size":151857,"stargazers_count":1112,"watchers_count":1112,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":409,"mirror_url":null,"open_issues_count":33,"forks":409,"open_issues":33,"watchers":1112,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/loomio/loomio/pulls/2863"},"html":{"href":"https://github.com/loomio/loomio/pull/2863"},"issue":{"href":"https://api.github.com/repos/loomio/loomio/issues/2863"},"comments":{"href":"https://api.github.com/repos/loomio/loomio/issues/2863/comments"},"review_comments":{"href":"https://api.github.com/repos/loomio/loomio/pulls/2863/comments"},"review_comment":{"href":"https://api.github.com/repos/loomio/loomio/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/loomio/loomio/pulls/2863/commits"},"statuses":{"href":"https://api.github.com/repos/loomio/loomio/statuses/490b10509f3e160a156247fe7dfdce98b97ba3fc"}}}}