The Plugin Manager system (PMS) is a status, issue and support system for Discourse plugins. It’s been developed by folks with years of experience maintaining Discourse plugins and working with users of those plugins. You can see the main interface at discourse.pluginmanager.org. This diagram will give you an overall sense of it, with each piece explained in more detail below.
Plugin Manager
The Plugin Manager is a Discourse plugin running on discourse.pluginmanager.org.
It has a number of jobs
- Maintain the master list of plugins supported by the PMS
- Maintain the status of each plugin, as reported by the Plugin Guard
- Gather the metadata for the plugin (beyond that in the plugin.rb file)
- Display its data in the Discourse client to Plugin Users
Plugin Guard
The Plugin Guard is a Discourse plugin running on the Canary Servers, and soon on client Discourse instances (i.e. whomever wants to install it).
It does the following
- Registers the plugins it finds on an instance it’s installed on with the Plugin Manager. This is authenticated by an API Key on Canary Servers and a User API Key on client servers.
- Tries to catch any errors caused by a plugin, primarily at startup
- If an error is caught, it removes the plugin and its assets from the active Discourse codebase to allow Discourse to continue functioning as normal
- Updates the status of its registered plugins on the Plugin Manager
Plugin Canary
The Plugin Canary is a Node.js app managing a plugin-focused version of the Discourse smoke test, running on the same server as the Plugin Manager and available at tests-passed.discourse.pluginmanager.org and stable.discourse.pluginmanager.org.
It does the following
- Runs scheduled plugin smoke tests on the Canary Servers
- Saves browser console logs of each smoke test for debugging purposes: https://tests-passed.discourse.pluginmanager.org/logs and https:/stable.discourse.pluginmanager.org/logs.
- If an issue is found it sends the relevant log and screenshot to the Plugin Guardian category on discourse.pluginmanager.org
Canary Servers
These are servers running
- Discourse
tests-passed
,stable
orbeta
- All plugins available in the Plugin Manager
- Plugin Guard, authorized with a site API Key
They are deployed and maintained as described in the Plugin Guard readme:
Other
The PMS also includes the following, which are self explanatory or described elsewhere:
- Process monitoring on Canary Servers via a SaaS monitoring service
- The Custom Wizard plugin for bug reports on plugins.discourse.pavilion.tech
- The Code Review plugin to sync issues from Github (soon)
FAQ
Why have you built this system?
This is part of Pavilion’s ongoing quest to find a sustainable ecosystem for open source software maintenance. The system is designed to incentivize the different stakeholders to maintain it for their own, and the collective, benefit. See further:
Why not just write more tests for plugins?
Tests are complimentary with, and part of, the PMS. If a plugin has tests and they’re integrated in a CI system supported by the Plugin Manager they will be used to update the plugin’s status. However, no matter how good tests are, you will still need QA (i.e. Guardians) and the reality is that most plugins will have only partial or no test coverage. It is always better if a plugin has tests, but the PMS is designed to accommodate plugins without tests.
Does this cost anything?
Everything is free for Administrators, Guardians and Maintainers. Use of discourse.pluginmanager.org will always be free for Users. There may be a small subscription fee to users for running the Plugin Guard on their own server (tbd when that is released). 100% of the fee would be used to help subsidize the running of the infrastructure, the development of the system, and if any is left over, to support the Administrators and Guardians.