. /** * Redis interface for GNU social queues * * @package GNUsocial * @author Miguel Dantas * @copyright 2019 Free Software Foundation, Inc http://www.fsf.org * @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later */ defined('GNUSOCIAL') || die(); class RedisQueuePlugin extends Plugin { const PLUGIN_VERSION = '0.1.0'; // settings which can be set in config.php with addPlugin('RedisQueue', ['param'=>'value', ...]); public $server = null; public function onStartNewQueueManager(?QueueManager &$qm) { $qm = new RedisQueueManager($this->server); return false; } public function onPluginVersion(array &$versions): bool { $versions[] = [ 'name' => 'RedisQueue', 'version' => self::PLUGIN_VERSION, 'author' => 'Miguel Dantas', 'homepage' => GNUSOCIAL_ENGINE_URL, 'description' => // TRANS: Plugin description. _m('Plugin implementing Redis as a backend for GNU social queues') ]; return true; } };