diff --git a/docs/admin.md b/docs/admin.md index 4956589bc..b2a8b754a 100644 --- a/docs/admin.md +++ b/docs/admin.md @@ -11,6 +11,6 @@ The Admin Dashboard has the following sections, being: - **Permissions** - Shows the permissions for each user group, and allows you to configure global and specific scopes. - **Appearance** - Allows you to customize the forum's colors, branding and add additional CSS for customization. - **Users** - Provides you with a paginated list of all the users in the forum, and grants you the ability to edit the user or take administrative actions. -- **Advanced** - Allows you to configure advanced settings such as Maintenance Mode, Search drivers, and more. +- **Advanced** - Allows you to configure advanced settings such as Maintenance Mode, Search drivers, Queue driver, and more. Apart from the above-mentioned sections, the Admin Dashboard also allows you to manage your Extensions (including the flarum core extensions such as Tags) under the _Features_ section. Extensions which modify the forum theme, or allow you to use multiple languages are categorized under the _Themes_ and _Languages_ section respectively. diff --git a/docs/config.md b/docs/config.md index fdfa195cf..0477205c9 100644 --- a/docs/config.md +++ b/docs/config.md @@ -32,9 +32,40 @@ Here's a quick overview of what everything means with an example file: 'api' => 'api', // /api goes to the API 'admin' => 'admin', // /admin goes to the admin ), + 'queue' => + array ( + 'driver' => 'sync', // Use the standard sync queue. Omitting this will entirely will have the same effect + ) +); +``` + +### Configuration via environment variables + +Whilst the file based method described here is suitable for most Flarum installations, scaled Flarum instances or those deployed via CI/CD will probably benefit from being configured via the environment. Here's an example of how to do this: + +```php + env('DEBUG') + ... ); ``` +This provides Flarum with the static configuration file it expects, but pulls variables from the environment at runtime. + +### Queues + +Flarum ships with support for two queue types - `sync` and `database`. Many tasks, or 'jobs' can be offloaded to a seperate process in order to improve response times and provide a better user experience. +* `sync` - default behaviour +* `database` - stores jobs in a dedicated database table, which are then processed via the [scheduler](/2.x/scheduler) in a seperate process. It is strongly advised that the scheduler is configured to run _every minute_ + +When the `database` queue is active, additional configuration options are available under `advanced settings`. + +![Database Queue Settings](https://private-user-images.githubusercontent.com/16573496/511708325-c4e8c663-b98e-45a9-a32f-d3be9a8f1aa6.png?jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3NjM5NzA5NTMsIm5iZiI6MTc2Mzk3MDY1MywicGF0aCI6Ii8xNjU3MzQ5Ni81MTE3MDgzMjUtYzRlOGM2NjMtYjk4ZS00NWE5LWEzMmYtZDNiZTlhOGYxYWE2LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTExMjQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUxMTI0VDA3NTA1M1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTRhNDM0ZTNlMDc4NjU5ZjBkYzVlZGZjNTNmYzExMTU4ZmVhMDhkOTA5OGM2NTRjYTYxZjNlYWI0NWNkNWI5ZGYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.Q8_b4O04wzKtqkaVyjukeucaR05r9oRPdNNvjODd2ME) + +##### Other queue processors + +At this point in time, use of other schedulers is supported, but configuration via `config.php` is not required. Example [FoF Horizon](https://FriendsOfFlarum/horizon) or [Redis Queues](https://FriendsOfFlarum/redis). + ### Maintenance modes Flarum has a maintenance mode that can be enabled by setting the `offline` key in the `config.php` file to one of the following values: